If the upper address bits don't match the interrupt delivery address
space window, entirely different behavior would need to be implemented.
Refuse such requests for the time being.
Replace adjacent hard tabs while introducing MSI_ADDR_BASE_MASK.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
ASSERT(pcidevs_locked());
+ if ( (address & MSI_ADDR_BASE_MASK) != MSI_ADDR_HEADER )
+ {
+ gdprintk(XENLOG_ERR, "%pp: PIRQ %u: unsupported address %lx\n",
+ &pdev->sbdf, pirq, address);
+ return -EOPNOTSUPP;
+ }
+
for ( i = 0; i < vectors; i++ )
{
uint8_t vector = MASK_EXTR(data, MSI_DATA_VECTOR_MASK);
* Shift/mask fields for msi address
*/
-#define MSI_ADDR_BASE_HI 0
-#define MSI_ADDR_BASE_LO 0xfee00000
+#define MSI_ADDR_BASE_HI 0
+#define MSI_ADDR_BASE_LO 0xfee00000
+#define MSI_ADDR_BASE_MASK (~0xfffff)
#define MSI_ADDR_HEADER MSI_ADDR_BASE_LO
#define MSI_ADDR_DESTMODE_SHIFT 2