On Wed, Nov 28, 2018 at 11:39:57AM +0000, Peter Maydell wrote: > On Wed, 28 Nov 2018 at 10:40, Samuel Ortiz <sa...@linux.intel.com> wrote: > > Given that this piece of code effectively builds a dependency to TCG > > from the KVM code, I see a few solutions but I need your input here. We > > could: > > > > - Decide we don't want to support --disable-tcg for ARM. We'd then carry > > this patch serie from the NEMU code repo. Worst case scenario, at > > least for us. > > - Manage to implement exception injection from userspace without TCG. > > Would it even be possible? > > - Offload exception injections back to the kernel in those cases. I feel > > this would be the cleanest solution but may need kernel changes. > > The kernel folk were firmly against 3, IIRC, but you can go > and have the discussion if you like. > > I don't really see what the problem is. This is just a bit > of code that's used by both TCG and KVM. Therefore it goes > in the binary whether TCG is enabled or not. Other functions > and bits of code are TCG only and therefore don't go in a > KVM-only binary. Keeping this code with --disable-tcg means:
Keep arm_cpu_do_interrupt -> Keep check_for_semihosting -> Keep the arm instruction loading code -> Keep a large chunk of the TCG core code itself. Does that dependency chain looks fine to you? Cheers, Samuel.