Skip to contentSkip to conversation

ACPI: LPSS: Prepare for SPI code cleanup

PATCH In review Andy Shevchenko 2 participants 5 messages Apr 4, 2024 – Apr 8, 2024 ACPI

lore
Share & tools
lore
#0 lore raw

v2 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.

This patch series should go before
https://lore.kernel.org/linux-acpi/[email protected]/

In v2:
- added Fixes tag to the first patch (Rafael)
- reordered to get Fixes first in the series
- v1: [email protected]

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

 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 v2 1/2 ACPI: LPSS: Advertise number of chip selects via property

Advertise number of chip selects via property for Intel Braswell.

Fixes 620c803f42de ("ACPI: LPSS: Provide an SSP type to the driver")
---
 drivers/acpi/acpi_lpss.c | 1 +
 1 file changed, 1 insertion(+)
drivers/acpi/acpi_lpss.c +1 -0
index 04e273167e92..8e01792228d1 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
#2 lore raw

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

In reply to Andy Shevchenko

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 8e01792228d1..a3d2d94be5c0 100644
@@ -887,10 +887,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
author Reviewed-by Kuppuswamy Sathyanarayanan on the v2 series
#3 lore raw
In reply to Andy Shevchenko
Quoted 5 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.

This patch series should go before
https://lore.kernel.org/linux-acpi/[email protected]/

Indeliberately forgot

(Code hasn't been changed, commit messages also stays the same, hence I added
it from v1)

Quoted 4 lines

In v2:
- added Fixes tag to the first patch (Rafael)
- reordered to get Fixes first in the series
- v1: [email protected]

Signature · 2 lines
With Best Regards,
Andy Shevchenko
#4 lore raw
Quoted 14 lines · Andy Shevchenko
Quoted 5 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.

This patch series should go before
https://lore.kernel.org/linux-acpi/[email protected]/

Indeliberately forgot

(Code hasn't been changed, commit messages also stays the same, hence I added
it from v1)

Quoted 6 lines
Quoted 4 lines

In v2:
- added Fixes tag to the first patch (Rafael)
- reordered to get Fixes first in the series
- v1: [email protected]

--

Both patches applied as 6.10 material, thanks!