* [PATCH] [Trivial] qib: fix an incorrect message @ 2012-07-19 19:34 Betty Dall 2012-07-19 18:03 ` Joe Perches 2012-07-19 18:24 ` Roland Dreier 0 siblings, 2 replies; 5+ messages in thread From: Betty Dall @ 2012-07-19 19:34 UTC (permalink / raw) To: trivial, linux-kernel, linux-rdma Cc: infinipath, roland, sean.hefty, hal.rosenstock, Betty Dall There is a cut and paste typo in the function qib_pci_slot_reset() where it prints that the "link_reset" function is called rather than the "slot_reset" function. This makes the message misleading. Signed-off-by: Betty Dall <betty.dall@hp.com> --- drivers/infiniband/hw/qib/qib_pcie.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/infiniband/hw/qib/qib_pcie.c b/drivers/infiniband/hw/qib/qib_pcie.c index 790646e..4f9d918 100644 --- a/drivers/infiniband/hw/qib/qib_pcie.c +++ b/drivers/infiniband/hw/qib/qib_pcie.c @@ -725,7 +725,7 @@ qib_pci_mmio_enabled(struct pci_dev *pdev) static pci_ers_result_t qib_pci_slot_reset(struct pci_dev *pdev) { - qib_devinfo(pdev, "QIB link_reset function called, ignored\n"); + qib_devinfo(pdev, "QIB slot_reset function called, ignored\n"); return PCI_ERS_RESULT_CAN_RECOVER; } -- 1.7.7 ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] [Trivial] qib: fix an incorrect message 2012-07-19 19:34 [PATCH] [Trivial] qib: fix an incorrect message Betty Dall @ 2012-07-19 18:03 ` Joe Perches 2012-07-19 18:56 ` Betty Dall 2012-07-19 18:24 ` Roland Dreier 1 sibling, 1 reply; 5+ messages in thread From: Joe Perches @ 2012-07-19 18:03 UTC (permalink / raw) To: Betty Dall Cc: trivial, linux-kernel, linux-rdma, infinipath, roland, sean.hefty, hal.rosenstock On Thu, 2012-07-19 at 13:34 -0600, Betty Dall wrote: > There is a cut and paste typo in the function qib_pci_slot_reset() where > it prints that the "link_reset" function is called rather than the > "slot_reset" function. This makes the message misleading. Hi Betty. > diff --git a/drivers/infiniband/hw/qib/qib_pcie.c b/drivers/infiniband/hw/qib/qib_pcie.c [] > @@ -725,7 +725,7 @@ qib_pci_mmio_enabled(struct pci_dev *pdev) > static pci_ers_result_t > qib_pci_slot_reset(struct pci_dev *pdev) > { > - qib_devinfo(pdev, "QIB link_reset function called, ignored\n"); > + qib_devinfo(pdev, "QIB slot_reset function called, ignored\n"); These sorts of typos can be avoided by using "%s: ", __func__ qib_devinfo(pdev, "QIB %s: called, ignored\n", __func__); cheers, Joe ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] [Trivial] qib: fix an incorrect message 2012-07-19 18:03 ` Joe Perches @ 2012-07-19 18:56 ` Betty Dall 2012-07-19 19:11 ` Joe Perches 0 siblings, 1 reply; 5+ messages in thread From: Betty Dall @ 2012-07-19 18:56 UTC (permalink / raw) To: Joe Perches Cc: trivial, linux-kernel, linux-rdma, infinipath, roland, sean.hefty, hal.rosenstock Hi Joe, Thanks for the comment Joe. It looks like Roland already accepted the trivial change. On Thu, 2012-07-19 at 11:03 -0700, Joe Perches wrote: > On Thu, 2012-07-19 at 13:34 -0600, Betty Dall wrote: > > There is a cut and paste typo in the function qib_pci_slot_reset() where > > it prints that the "link_reset" function is called rather than the > > "slot_reset" function. This makes the message misleading. > > Hi Betty. > > > diff --git a/drivers/infiniband/hw/qib/qib_pcie.c b/drivers/infiniband/hw/qib/qib_pcie.c > [] > > @@ -725,7 +725,7 @@ qib_pci_mmio_enabled(struct pci_dev *pdev) > > static pci_ers_result_t > > qib_pci_slot_reset(struct pci_dev *pdev) > > { > > - qib_devinfo(pdev, "QIB link_reset function called, ignored\n"); > > + qib_devinfo(pdev, "QIB slot_reset function called, ignored\n"); > > These sorts of typos can be avoided by using "%s: ", __func__ > > qib_devinfo(pdev, "QIB %s: called, ignored\n", __func__); You are right about using __func__. That is what I use typically too. In this file, none of the qib_devinfo() messages use __func__, so I stuck with the trivial change for consistency. I could write another patch that makes use of __func__ for all the appropriate qib_devinfo() calls (there are 4 of them.) Do you think that is a worthwhile change? BTW, I did review all the other qib_devinfo() calls to make sure they are using the correct function names, and they look good. -Betty ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] [Trivial] qib: fix an incorrect message 2012-07-19 18:56 ` Betty Dall @ 2012-07-19 19:11 ` Joe Perches 0 siblings, 0 replies; 5+ messages in thread From: Joe Perches @ 2012-07-19 19:11 UTC (permalink / raw) To: Betty Dall Cc: trivial, linux-kernel, linux-rdma, infinipath, roland, sean.hefty, hal.rosenstock On Thu, 2012-07-19 at 12:56 -0600, Betty Dall wrote: > Thanks for the comment Joe. It looks like Roland already accepted the > trivial change. No worries. > On Thu, 2012-07-19 at 11:03 -0700, Joe Perches wrote: > > On Thu, 2012-07-19 at 13:34 -0600, Betty Dall wrote: [] > > > diff --git a/drivers/infiniband/hw/qib/qib_pcie.c b/drivers/infiniband/hw/qib/qib_pcie.c > > [] > > > @@ -725,7 +725,7 @@ qib_pci_mmio_enabled(struct pci_dev *pdev) > > > static pci_ers_result_t > > > qib_pci_slot_reset(struct pci_dev *pdev) > > > { > > > - qib_devinfo(pdev, "QIB link_reset function called, ignored\n"); > > > + qib_devinfo(pdev, "QIB slot_reset function called, ignored\n"); > > > > These sorts of typos can be avoided by using "%s: ", __func__ > > > > qib_devinfo(pdev, "QIB %s: called, ignored\n", __func__); > > You are right about using __func__. That is what I use typically too. In > this file, none of the qib_devinfo() messages use __func__, so I stuck > with the trivial change for consistency. I could write another patch > that makes use of __func__ for all the appropriate qib_devinfo() calls > (there are 4 of them.) Do you think that is a worthwhile change? BTW, I > did review all the other qib_devinfo() calls to make sure they are using > the correct function names, and they look good. Thanks for checking Betty. It's hard for me to answer, I'm not the maintainer. Maybe Roland has a preference. I'd probably rename qib_devinfo to qib_info or qib_pdev_info (adding an _ before info for consistency) and change the macro definitions removing the unnecessary do {} while (0). Single statement macros don't need to be: #define macro(fmt, ...) \ do { \ single_stmt(fmt, ##__VA_ARGS__); \ } while (0) and are probably better as: #define macro(fmt, ...) \ single_stmt(fmt, ##__VA_ARGS__) cheers, Joe ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] [Trivial] qib: fix an incorrect message 2012-07-19 19:34 [PATCH] [Trivial] qib: fix an incorrect message Betty Dall 2012-07-19 18:03 ` Joe Perches @ 2012-07-19 18:24 ` Roland Dreier 1 sibling, 0 replies; 5+ messages in thread From: Roland Dreier @ 2012-07-19 18:24 UTC (permalink / raw) To: Betty Dall Cc: trivial, linux-kernel, linux-rdma, infinipath, sean.hefty, hal.rosenstock thanks, applied. ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-07-19 19:11 UTC | newest] Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2012-07-19 19:34 [PATCH] [Trivial] qib: fix an incorrect message Betty Dall 2012-07-19 18:03 ` Joe Perches 2012-07-19 18:56 ` Betty Dall 2012-07-19 19:11 ` Joe Perches 2012-07-19 18:24 ` Roland Dreier
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®