From bfb11bec3b3fec638adf864a9b9b2cff6671fed8 Mon Sep 17 00:00:00 2001 From: Nicholas Sudsgaard Date: Tue, 30 Jan 2024 09:53:46 +0900 Subject: include/device/device.h: Remove CHIP_NAME() macro Macros can be confusing on their own; hiding commas make things worse. This can sometimes be downright misleading. A "good" example would be the code in soc/intel/xeon_sp/spr/chip.c: CHIP_NAME("Intel SapphireRapids-SP").enable_dev = chip_enable_dev, This appears as CHIP_NAME() being some struct when in fact these are defining 2 separate members of the same struct. It was decided to remove this macro altogether, as it does not do anything special and incurs a maintenance burden. Change-Id: Iaed6dfb144bddcf5c43634b0c955c19afce388f0 Signed-off-by: Nicholas Sudsgaard Reviewed-on: https://review.coreboot.org/c/coreboot/+/80239 Reviewed-by: Yidi Lin Reviewed-by: Felix Singer Reviewed-by: Jakub Czapiga Tested-by: build bot (Jenkins) Reviewed-by: Matt DeVillier --- src/drivers/soundwire/alc1308/alc1308.c | 2 +- src/drivers/soundwire/alc5682/alc5682.c | 2 +- src/drivers/soundwire/alc711/alc711.c | 2 +- src/drivers/soundwire/cs42l42/cs42l42.c | 2 +- src/drivers/soundwire/max98363/max98363.c | 2 +- src/drivers/soundwire/max98373/max98373.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src/drivers/soundwire') diff --git a/src/drivers/soundwire/alc1308/alc1308.c b/src/drivers/soundwire/alc1308/alc1308.c index f16d3a2de5..5449fe8648 100644 --- a/src/drivers/soundwire/alc1308/alc1308.c +++ b/src/drivers/soundwire/alc1308/alc1308.c @@ -146,6 +146,6 @@ static void soundwire_alc1308_enable(struct device *dev) } struct chip_operations drivers_soundwire_alc1308_ops = { - CHIP_NAME("Realtek ALC1308 SoundWire Codec") + .name = "Realtek ALC1308 SoundWire Codec", .enable_dev = soundwire_alc1308_enable }; diff --git a/src/drivers/soundwire/alc5682/alc5682.c b/src/drivers/soundwire/alc5682/alc5682.c index c1aaff6cb7..0d8a3ab061 100644 --- a/src/drivers/soundwire/alc5682/alc5682.c +++ b/src/drivers/soundwire/alc5682/alc5682.c @@ -174,6 +174,6 @@ static void soundwire_alc5682_enable(struct device *dev) } struct chip_operations drivers_soundwire_alc5682_ops = { - CHIP_NAME("Realtek ALC5682 SoundWire Codec") + .name = "Realtek ALC5682 SoundWire Codec", .enable_dev = soundwire_alc5682_enable }; diff --git a/src/drivers/soundwire/alc711/alc711.c b/src/drivers/soundwire/alc711/alc711.c index 34d55c78e4..cfe28ade0c 100644 --- a/src/drivers/soundwire/alc711/alc711.c +++ b/src/drivers/soundwire/alc711/alc711.c @@ -151,6 +151,6 @@ static void soundwire_alc711_enable(struct device *dev) } struct chip_operations drivers_soundwire_alc711_ops = { - CHIP_NAME("Realtek ALC711 SoundWire Codec") + .name = "Realtek ALC711 SoundWire Codec", .enable_dev = soundwire_alc711_enable }; diff --git a/src/drivers/soundwire/cs42l42/cs42l42.c b/src/drivers/soundwire/cs42l42/cs42l42.c index 111844c171..e7c14cc434 100644 --- a/src/drivers/soundwire/cs42l42/cs42l42.c +++ b/src/drivers/soundwire/cs42l42/cs42l42.c @@ -226,6 +226,6 @@ static void soundwire_cs42l42_enable(struct device *dev) } struct chip_operations drivers_soundwire_cs42l42_ops = { - CHIP_NAME("Cirrus Logic CS42L42 SoundWire Codec") + .name = "Cirrus Logic CS42L42 SoundWire Codec", .enable_dev = soundwire_cs42l42_enable }; diff --git a/src/drivers/soundwire/max98363/max98363.c b/src/drivers/soundwire/max98363/max98363.c index 2963cdaa4e..7b90d7834b 100644 --- a/src/drivers/soundwire/max98363/max98363.c +++ b/src/drivers/soundwire/max98363/max98363.c @@ -136,6 +136,6 @@ static void soundwire_max98363_enable(struct device *dev) } struct chip_operations drivers_soundwire_max98363_ops = { - CHIP_NAME("Maxim MAX98363 SoundWire Codec") + .name = "Maxim MAX98363 SoundWire Codec", .enable_dev = soundwire_max98363_enable }; diff --git a/src/drivers/soundwire/max98373/max98373.c b/src/drivers/soundwire/max98373/max98373.c index fb202fe811..e3107c4a4c 100644 --- a/src/drivers/soundwire/max98373/max98373.c +++ b/src/drivers/soundwire/max98373/max98373.c @@ -160,6 +160,6 @@ static void soundwire_max98373_enable(struct device *dev) } struct chip_operations drivers_soundwire_max98373_ops = { - CHIP_NAME("Maxim MAX98373 SoundWire Codec") + .name = "Maxim MAX98373 SoundWire Codec", .enable_dev = soundwire_max98373_enable }; -- cgit v1.2.3