Skip to contentSkip to conversation

Revert "ssb: Prevent build of PCI host features in module"

PATCH In review Rafał Miłecki 5 participants 11 messages May 11, 2018 – May 12, 2018 Sonics silicon backplane driver (ssb)

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/2 Revert "ssb: Prevent build of PCI host features in module"

From: Rafał Miłecki <[email protected]>

This reverts commit 882164a4a928bcaa53280940436ca476e6b1db8e.

Above commit added "SSB = y" dependency to the wrong symbol SSB_DRIVER_PCICORE_POSSIBLE and prevented SSB_DRIVER_PCICORE from being selected when needed. PCI core driver for core running in clienthost mode is important for bus initialization. It's perfectly valid scenario to have ssb built as module and use it with buses on PCI cards.

This fixes regression that affected all *module* users with PCI cards.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1572349

---
 drivers/ssb/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/ssb/Kconfig +1 -1
index 9371651d8017..b3f5cae98ea6 100644
@@ -117,7 +117,7 @@ config SSB_SERIAL
 
 config SSB_DRIVER_PCICORE_POSSIBLE
 	bool
-	depends on SSB_PCIHOST && SSB = y
+	depends on SSB_PCIHOST
 	default y
 
 config SSB_DRIVER_PCICORE
Signature · 1 line
2.13.6
#1 lore raw

PATCH v2 2/2 ssb: make SSB_PCICORE_HOSTMODE depend on SSB = y

From: Rafał Miłecki <[email protected]>

SSB_PCICORE_HOSTMODE protects MIPS specific code that calls not exported symbols pcibios_enable_device and register_pci_controller. This code is supposed to be compiled only with ssb builtin.

This fixes:
ERROR: "pcibios_enable_device" [drivers/ssb/ssb.ko] undefined!
ERROR: "register_pci_controller" [drivers/ssb/ssb.ko] undefined! make[1]: *** [scripts/Makefile.modpost:92: __modpost] Error 1

---
V2: Add Reported-by and Reviewed-by

---
 drivers/ssb/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/ssb/Kconfig +1 -1
index b3f5cae98ea6..c574dd210500 100644
@@ -131,7 +131,7 @@ config SSB_DRIVER_PCICORE
 
 config SSB_PCICORE_HOSTMODE
 	bool "Hostmode support for SSB PCI core"
-	depends on SSB_DRIVER_PCICORE && SSB_DRIVER_MIPS
+	depends on SSB_DRIVER_PCICORE && SSB_DRIVER_MIPS && SSB = y
 	help
 	  PCIcore hostmode operation (external PCI bus).
 
Signature · 1 line
2.13.6
#2 lore raw
In reply to Rafał Miłecki
Quoted 10 lines · On 11 May 2018 at 11:17, Rafa=C5=82 Mi=C5=82ecki <[email protected]> wrote:

From: Rafa=C5=82 Mi=C5=82ecki <[email protected]>

This reverts commit 882164a4a928bcaa53280940436ca476e6b1db8e.

Above commit added "SSB =3D y" dependency to the wrong symbol SSB_DRIVER_PCICORE_POSSIBLE and prevented SSB_DRIVER_PCICORE from being selected when needed. PCI core driver for core running in clienthost mode is important for bus initialization. It's perfectly valid scenario to have ssb built as module and use it with buses on PCI cards.

Quoted 4 lines

This fixes regression that affected all *module* users with PCI cards.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=3D1572349

As these patches fix regression/build error, I believe both should get into 4.17.

#3 lore raw
Quoted 11 lines · Rafa=C5=82 Mi=C5=82ecki <[email protected]> writes:
Quoted 10 lines · On 11 May 2018 at 11:17, Rafa=C5=82 Mi=C5=82ecki <[email protected]> wrote:

From: Rafa=C5=82 Mi=C5=82ecki <[email protected]>

This reverts commit 882164a4a928bcaa53280940436ca476e6b1db8e.

Above commit added "SSB =3D y" dependency to the wrong symbol SSB_DRIVER_PCICORE_POSSIBLE and prevented SSB_DRIVER_PCICORE from being selected when needed. PCI core driver for core running in clienthost mode is important for bus initialization. It's perfectly valid scenario to have ssb built as module and use it with buses on PCI cards.

Quoted 7 lines
Quoted 4 lines

This fixes regression that affected all *module* users with PCI cards.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=3D1572349

As these patches fix regression/build error, I believe both should get into 4.17.

How much confidence do we have that we don't need to end up reverting patch 2 as well? I rather be pushing patch 2 to 4.18 so that there's more time for testing and waiting for feedback.

--=20
Kalle Valo

#4 lore raw
Quoted 3 lines · Kalle Valo
Quoted 1 line · Rafa=C5=82 Mi=C5=82ecki <[email protected]> writes:

On 11 May 2018 at 11:17, Rafa=C5=82 Mi=C5=82ecki <[email protected]> wrot=

e:

Quoted 15 lines
Quoted 15 lines
Quoted 14 lines

From: Rafa=C5=82 Mi=C5=82ecki <[email protected]>

This reverts commit 882164a4a928bcaa53280940436ca476e6b1db8e.

Above commit added "SSB =3D y" dependency to the wrong symbol SSB_DRIVER_PCICORE_POSSIBLE and prevented SSB_DRIVER_PCICORE from being selected when needed. PCI core driver for core running in clienthost mode is important for bus initialization. It's perfectly valid scenario to have ssb built as module and use it with buses on PCI cards.

This fixes regression that affected all *module* users with PCI cards.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=3D1572349

Quoted 6 lines
Quoted 2 lines

As these patches fix regression/build error, I believe both should get into 4.17.

How much confidence do we have that we don't need to end up reverting patch 2 as well? I rather be pushing patch 2 to 4.18 so that there's more time for testing and waiting for feedback.

Solution from 2/2 seems pretty obvious.

1) Enabling SSB_PCICORE_HOSTMODE compiles code that requires non-exported symbols. Requiring "SSB =3D y" seems pretty obvious.
2) As pointed in another e-mail bcma has pretty identical solution that seems to be working well, see commit 79ca239a68f8f ("bcma:
Prevent build of PCI host features in module").

That's just my opinion though, I shared since you asked.

If you prefer to queue that for 4.18, I'm OK. After all:
1) This problem affects MIPS arch only
2) It can be fixed by not selecting BCMA_DRIVER_PCI_HOSTMODE for SSB =3D m

--=20
Rafa=C5=82

#5 lore raw
In reply to Kalle Valo
Quoted 18 lines · Kalle Valo
Quoted 16 lines · Rafał Miłecki
Quoted 14 lines · Rafał Miłecki

From: Rafał Miłecki <[email protected]>

This reverts commit 882164a4a928bcaa53280940436ca476e6b1db8e.

Above commit added "SSB = y" dependency to the wrong symbol SSB_DRIVER_PCICORE_POSSIBLE and prevented SSB_DRIVER_PCICORE from being selected when needed. PCI core driver for core running in clienthost mode is important for bus initialization. It's perfectly valid scenario to have ssb built as module and use it with buses on PCI cards.

This fixes regression that affected all *module* users with PCI cards.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1572349

Quoted 6 lines
Quoted 2 lines

As these patches fix regression/build error, I believe both should get into 4.17.

How much confidence do we have that we don't need to end up reverting patch 2 as well? I rather be pushing patch 2 to 4.18 so that there's more time for testing and waiting for feedback.

Although I do not have the hardware to test the builds, I worked closely with the OP in the bug at b.r.c noted above. From that effort, it became clear what configuration variables were missing to cause the x86 failures. Patch 2 satisfies the requirement, and prevents the build problems found by the MIPS users. Both patches are needed in 4.17.

Larry

#6 lore raw
Quoted 4 lines · Larry Finger
Quoted 3 lines · Kalle Valo
Quoted 1 line · Rafa=C5=82 Mi=C5=82ecki <[email protected]> writes:

On 11 May 2018 at 11:17, Rafa=C5=82 Mi=C5=82ecki <[email protected]> wro=

te:

Quoted 22 lines
Quoted 15 lines
Quoted 15 lines
Quoted 14 lines

From: Rafa=C5=82 Mi=C5=82ecki <[email protected]>

This reverts commit 882164a4a928bcaa53280940436ca476e6b1db8e.

Above commit added "SSB =3D y" dependency to the wrong symbol SSB_DRIVER_PCICORE_POSSIBLE and prevented SSB_DRIVER_PCICORE from being selected when needed. PCI core driver for core running in clienthost mode is important for bus initialization. It's perfectly valid scenario to have ssb built as module and use it with buses on PCI cards.

This fixes regression that affected all *module* users with PCI cards.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=3D1572349

Quoted 6 lines
Quoted 2 lines

As these patches fix regression/build error, I believe both should get into 4.17.

How much confidence do we have that we don't need to end up reverting patch 2 as well? I rather be pushing patch 2 to 4.18 so that there's more time for testing and waiting for feedback.

Quoted 6 lines

Although I do not have the hardware to test the builds, I worked closely with the OP in the bug at b.r.c noted above. From that effort, it became clear what configuration variables were missing to cause the x86 failures. Patch 2 satisfies the requirement, and prevents the build problems found by the MIPS users. Both patches are needed in 4.17.

And I assume Michael is ok with this approach as well as I haven't heard from him. I'll then push both of these to 4.17.

--=20
Kalle Valo

maintainer
#7 lore raw
Quoted 22 lines · On Sat, 12 May 2018 10:50:42 +0300 Kalle Valo <[email protected]> wrote:
Quoted 4 lines · Larry Finger
Quoted 3 lines · Kalle Valo
Quoted 1 line · Rafał Miłecki

On 11 May 2018 at 11:17, Rafał Miłecki <[email protected]> wrote:

[...]

Quoted 8 lines
Quoted 7 lines
Quoted 3 lines

As these patches fix regression/build error, I believe both should get into 4.17.

How much confidence do we have that we don't need to end up reverting patch 2 as well? I rather be pushing patch 2 to 4.18 so that there's more time for testing and waiting for feedback.

Quoted 6 lines

Although I do not have the hardware to test the builds, I worked closely with the OP in the bug at b.r.c noted above. From that effort, it became clear what configuration variables were missing to cause the x86 failures. Patch 2 satisfies the requirement, and prevents the build problems found by the MIPS users. Both patches are needed in 4.17.

Quoted 3 lines

And I assume Michael is ok with this approach as well as I haven't heard from him. I'll then push both of these to 4.17.

Yes, I'm OK with the patch, if we have a third patch that cleans up the PCI_DRIVERS_LEGACY dependency by moving it to SSB_PCICORE_HOSTMODE where it belongs. (This doesn't need to go into the stable tree.) We currently implicitly get that via dependency chain, so this is OK for now as-is.

Signature · 1 line
Michael
#8 lore raw
Quoted 29 lines · Michael Büsch
Quoted 22 lines · On Sat, 12 May 2018 10:50:42 +0300 Kalle Valo <[email protected]> wrote:
Quoted 4 lines · Larry Finger
Quoted 3 lines · Kalle Valo
Quoted 1 line · Rafał Miłecki

On 11 May 2018 at 11:17, Rafał Miłecki <[email protected]> wrote:

[...]

Quoted 8 lines
Quoted 7 lines
Quoted 3 lines

As these patches fix regression/build error, I believe both should get into 4.17.

How much confidence do we have that we don't need to end up reverting patch 2 as well? I rather be pushing patch 2 to 4.18 so that there's more time for testing and waiting for feedback.

Quoted 6 lines

Although I do not have the hardware to test the builds, I worked closely with the OP in the bug at b.r.c noted above. From that effort, it became clear what configuration variables were missing to cause the x86 failures. Patch 2 satisfies the requirement, and prevents the build problems found by the MIPS users. Both patches are needed in 4.17.

Quoted 3 lines

And I assume Michael is ok with this approach as well as I haven't heard from him. I'll then push both of these to 4.17.

Quoted 5 lines

Yes, I'm OK with the patch, if we have a third patch that cleans up the PCI_DRIVERS_LEGACY dependency by moving it to SSB_PCICORE_HOSTMODE where it belongs. (This doesn't need to go into the stable tree.) We currently implicitly get that via dependency chain, so this is OK for now as-is.

I'm planning to handle PCI_DRIVERS_LEGACY cleanup once my patches hit net-next.git and then wireless-drivers-next.git. It's to avoid conflicts.

maintainer
#9 lore raw
Quoted 9 lines · On Sat, 12 May 2018 12:00:07 +0200 Rafał Miłecki <[email protected]> wrote:
Quoted 5 lines

Yes, I'm OK with the patch, if we have a third patch that cleans up the PCI_DRIVERS_LEGACY dependency by moving it to SSB_PCICORE_HOSTMODE where it belongs. (This doesn't need to go into the stable tree.) We currently implicitly get that via dependency chain, so this is OK for now as-is.

I'm planning to handle PCI_DRIVERS_LEGACY cleanup once my patches hit net-next.git and then wireless-drivers-next.git. It's to avoid conflicts.

Yes, thanks. Take your time. We're not in a hurry. :) This change should not make a functional difference.

Signature · 1 line
Michael
#10 lore raw
In reply to Rafał Miłecki
Quoted 10 lines · Rafał Miłecki

From: Rafał Miłecki <[email protected]>

This reverts commit 882164a4a928bcaa53280940436ca476e6b1db8e.

Above commit added "SSB = y" dependency to the wrong symbol SSB_DRIVER_PCICORE_POSSIBLE and prevented SSB_DRIVER_PCICORE from being selected when needed. PCI core driver for core running in clienthost mode is important for bus initialization. It's perfectly valid scenario to have ssb built as module and use it with buses on PCI cards.

Quoted 4 lines

This fixes regression that affected all *module* users with PCI cards.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1572349

2 patches applied to wireless-drivers.git, thanks.

36910d82a80c Revert "ssb: Prevent build of PCI host features in module" ebd27d3317c6 ssb: make SSB_PCICORE_HOSTMODE depend on SSB = y

Signature · 3 lines
https://patchwork.kernel.org/patch/10393729/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches