Re: [PATCH 0/2] Fixes for Switchtec Driver
From: Bjorn Helgaas
Date: Mon May 22 2017 - 17:54:16 EST
On Mon, May 15, 2017 at 10:44:51AM -0600, Logan Gunthorpe wrote:
> Hi Bjorn,
>
> Can you please apply the following two patches? The first is
> a cleanup to use a new helper function I added (it had to wait
> until both patchsets were in). The second is a minor bug fix to
> the driver we found last week.
>
> Thanks!
>
> Logan
>
>
> Logan Gunthorpe (2):
> switchtec: utilize new device_add_cdev helper function
> switchtec: fix minor bug with partition id register
>
> drivers/pci/switch/switchtec.c | 16 ++++++----------
> 1 file changed, 6 insertions(+), 10 deletions(-)
Since we merged the Switchtec driver during the v4.12 merge window, I
applied these to for-linus for v4.12, with the following changelogs to
correct a few typos:
commit 9871e9bb5cf6
Author: Logan Gunthorpe <logang@xxxxxxxxxxxx>
Date: Mon May 22 16:52:30 2017 -0500
switchtec: Fix minor bug with partition ID register
When a switch endpoint is configured without NTB, the mmio_ntb registers
will read all zeros. However, in corner case configurations where the
partition ID is not zero and NTB is not enabled, the code will have the
wrong partition ID and this causes the driver to use the wrong set of
drivers. To fix this we simply take the partition ID from the system info
region.
Reported-by: Dingbao Chen <dingbao.chen@xxxxxxxxxxxxx>
Signed-off-by: Logan Gunthorpe <logang@xxxxxxxxxxxx>
Signed-off-by: Bjorn Helgaas <bhelgaas@xxxxxxxxxx>
commit e40cf640b8f6 (refs/patches/for-linus/switchtec-use-new)
Author: Logan Gunthorpe <logang@xxxxxxxxxxxx>
Date: Mon May 22 16:52:24 2017 -0500
switchtec: Use new cdev_device_add() helper function
Convert from "cdev_add() + device_add()" to cdev_device_add(), and from
"device_del() + cdev_del()" to cdev_device_del().
[bhelgaas: changelog]
Signed-off-by: Logan Gunthorpe <logang@xxxxxxxxxxxx>
Signed-off-by: Bjorn Helgaas <bhelgaas@xxxxxxxxxx>