Skip to contentSkip to conversation

ACPI: LPSS: Prepare for SPI code cleanup

PATCH Superseded Andy Shevchenko 3 participants 7 messages Apr 2, 2024 – Apr 4, 2024 ACPI

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

cover ACPI: LPSS: Prepare for SPI code cleanup

An ad-hoc cleanup followed by preparation for SPI code cleaning. The latter will be done in the next kernel cycle to avoid conflicts.

Andy Shevchenko (2):
ACPI: LPSS: Remove nested ifdeffery for CONFIG_PM
ACPI: LPSS: Advertise number of chip selects via property

 drivers/acpi/acpi_lpss.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
Signature · 1 line
2.43.0.rc1.1.gbec44491f096
#1 lore raw

PATCH 1/2 ACPI: LPSS: Remove nested ifdeffery for CONFIG_PM

There is no need to have the ifdef CONFIG_PM to be nested. The second and so on will obviously become a no-op.

Remove redundant nested ifdeffery.

---
 drivers/acpi/acpi_lpss.c | 2 --
 1 file changed, 2 deletions(-)
drivers/acpi/acpi_lpss.c +0 -2
index 04e273167e92..5b56f198d005 100644
@@ -886,10 +886,8 @@ static int acpi_lpss_activate(struct device *dev)
 	if (pdata->dev_desc->flags & (LPSS_SAVE_CTX | LPSS_SAVE_CTX_ONCE))
 		lpss_deassert_reset(pdata);
 
-#ifdef CONFIG_PM
 	if (pdata->dev_desc->flags & LPSS_SAVE_CTX_ONCE)
 		acpi_lpss_save_ctx(dev, pdata);
-#endif
 
 	return 0;
 }
Signature · 1 line
2.43.0.rc1.1.gbec44491f096
#2 lore raw

PATCH 2/2 ACPI: LPSS: Advertise number of chip selects via property

In reply to Andy Shevchenko

Advertise number of chip selects via property for Intel Braswell.

---
 drivers/acpi/acpi_lpss.c | 1 +
 1 file changed, 1 insertion(+)
drivers/acpi/acpi_lpss.c +1 -0
index 5b56f198d005..a3d2d94be5c0 100644
@@ -325,6 +325,7 @@ static const struct lpss_device_desc bsw_i2c_dev_desc = {
 
 static const struct property_entry bsw_spi_properties[] = {
 	PROPERTY_ENTRY_U32("intel,spi-pxa2xx-type", LPSS_BSW_SSP),
+	PROPERTY_ENTRY_U32("num-cs", 2),
 	{ }
 };
 
Signature · 1 line
2.43.0.rc1.1.gbec44491f096
#3 lore raw

Re: [PATCH v1 2/2] ACPI: LPSS: Advertise number of chip selects via property

Quoted 4 lines · Andy Shevchenko

Advertise number of chip selects via property for Intel Braswell.

A Fixes: tag, please?

Also, IIUC this should be applied before
https://lore.kernel.org/linux-acpi/[email protected]/
?

Quoted 19 lines
---
 drivers/acpi/acpi_lpss.c | 1 +
 1 file changed, 1 insertion(+)
drivers/acpi/acpi_lpss.c +1 -1
index 5b56f198d005..a3d2d94be5c0 100644
@@ -325,6 +325,7 @@ static const struct lpss_device_desc bsw_i2c_dev_desc = {
 
 static const struct property_entry bsw_spi_properties[] = {
        PROPERTY_ENTRY_U32("intel,spi-pxa2xx-type", LPSS_BSW_SSP),
+       PROPERTY_ENTRY_U32("num-cs", 2),
        { }
 };
 
--

2.43.0.rc1.1.gbec44491f096

#4 lore raw

Re: [PATCH v1 2/2] ACPI: LPSS: Advertise number of chip selects via property

Quoted 8 lines · Rafael J. Wysocki
Quoted 4 lines · Andy Shevchenko

Advertise number of chip selects via property for Intel Braswell.

A Fixes: tag, please?

Sure.

Quoted 3 lines

Also, IIUC this should be applied before
https://lore.kernel.org/linux-acpi/[email protected]/
?

I believe yes for the sake of simplicity in maintaining / backporting (if needed).

Signature · 2 lines
With Best Regards,
Andy Shevchenko
#5 lore raw
In reply to Andy Shevchenko
Quoted 2 lines · Andy Shevchenko

An ad-hoc cleanup followed by preparation for SPI code cleaning. The latter will be done in the next kernel cycle to avoid conflicts.

Thinking more about these two, it might be even possible to put them as amendments for v6.9-rc3, but I'm fine to have them for v6.10-rc1. Just speaking out my thoughts, whatever is better for you is good for me.

Signature · 2 lines
With Best Regards,
Andy Shevchenko
Reviewed-by on the v1 series
#6 lore raw
In reply to Andy Shevchenko
Quoted 2 lines · Andy Shevchenko

An ad-hoc cleanup followed by preparation for SPI code cleaning. The latter will be done in the next kernel cycle to avoid conflicts.

Looks good to me.

Quoted 7 lines

Andy Shevchenko (2):
ACPI: LPSS: Remove nested ifdeffery for CONFIG_PM
ACPI: LPSS: Advertise number of chip selects via property

 drivers/acpi/acpi_lpss.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
Signature · 2 lines
Sathyanarayanan Kuppuswamy
Linux Kernel Developer