[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] arm/acpi: hide watchdog timer in GTDT table for dom0



On 30/11/16 14:31, Shanker Donthineni wrote:
Hi Julien,

Hi Shanker,


On 11/30/2016 04:29 AM, Julien Grall wrote:
Hi Shanker,

On 29/11/2016 02:59, Shanker Donthineni wrote:
Either we have to hide the watchdog timer section in GTDT or emulate
watchdog timer block for dom0. Otherwise, system gets panic when
dom0 accesses its MMIO registers. The current XEN doesn't support
virtualization of watchdog timer, so hide the watchdog timer section
for dom0.

IHMO, the patch description is not really accurate. You are removing
the platform timer array that contains watchdog but also Block Timer.

Whilst you mention watchdog, you don't have a word on the Block Timer.


Sure, I'll include detailed description that has word  'Block Timer'.

Taking a step back, DOM0 is not able to use it because it does not
request to map the memory region (this is the behavior expected for
PCI and AMBA devices). So this is a bug in the kernel for me.

Not all the drivers/modules in the Linux kernel are bounded to a device
object 'struct device'.  The watchdog timer driver is one of this
category, neither a PCIe nor a AMBA device.

You can find GTDT watchdog timer code at
https://lkml.org/lkml/2016/7/25/34.

This link points to an i2c driver. Did you intend to post a different link?


Assuming this would be fixed, what would be the drawback to give
access to dom0 to the watchdogs?

Absolutely no problem.

My worry with that change is what if in the future we decide to expose
watchdog to DOM0? Linux will still not be ready, unless we have Xen to
map those regions at DOM0 build time. That would break the design we
have for ACPI.


Agree, I was also thinking in the same direction. Let me create a v2
patch that does stage-2 map of MMIO regions at the time of building the
dom0 domain to fix the problem.

You didn't understand my point here. The design we agreed for ACPI
support is DOM0 should request the mapping before using any device. This is because Xen cannot know in advance the memory attribute to use.

So for me this solution is just a workaround. It does not address the real problem that Linux does not request the mapping of the memory region before using it. So we will end up with the same problem later if a device is neither AMBA, nor PCI.

This is easy to solve because watchdog are described the static tables. What if the device is described in ASL?

Regards,

--
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.