diff options
author | Ira Weiny <ira.weiny@intel.com> | 2023-05-17 14:28:11 -0700 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2023-09-15 22:02:04 -0700 |
commit | 1b27978d69670282a1586465de640cff363a34d8 (patch) | |
tree | 8158457c3fe1c2ebef8b4900a3790ceb24a725b9 /drivers/cxl/pci.c | |
parent | 7914992b37d5a4b165e65a32a7723afde9356720 (diff) |
cxl/pci: Update comment
The existence of struct cxl_dev_id containing a single member is odd.
The comment made sense when I wrote it but could be clarified.
Update the comment and place it next to the odd looking structure.
Signed-off-by: Ira Weiny <ira.weiny@intel.com>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Dave Jiang <dave.jiang@intel.com>
Link: https://lore.kernel.org/r/20230426-cxl-fixes-v1-2-870c4c8b463a@intel.com
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/cxl/pci.c')
-rw-r--r-- | drivers/cxl/pci.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/cxl/pci.c b/drivers/cxl/pci.c index 44a21ab7add5..2061e278e47b 100644 --- a/drivers/cxl/pci.c +++ b/drivers/cxl/pci.c @@ -85,6 +85,10 @@ static int cxl_pci_mbox_wait_for_doorbell(struct cxl_dev_state *cxlds) status & CXLMDEV_DEV_FATAL ? " fatal" : "", \ status & CXLMDEV_FW_HALT ? " firmware-halt" : "") +/* + * Threaded irq dev_id's must be globally unique. cxl_dev_id provides a unique + * wrapper object for each irq within the same cxlds. + */ struct cxl_dev_id { struct cxl_dev_state *cxlds; }; @@ -95,7 +99,6 @@ static int cxl_request_irq(struct cxl_dev_state *cxlds, int irq, struct device *dev = cxlds->dev; struct cxl_dev_id *dev_id; - /* dev_id must be globally unique and must contain the cxlds */ dev_id = devm_kzalloc(dev, sizeof(*dev_id), GFP_KERNEL); if (!dev_id) return -ENOMEM; |