[coreboot-gerrit] Change in coreboot[master]: mb/lenovo: Get rid of device_t

Elyes HAOUAS (Code Review) gerrit at coreboot.org
Fri May 4 22:05:47 CEST 2018


Elyes HAOUAS has uploaded this change for review. ( https://review.coreboot.org/26101


Change subject: mb/lenovo: Get rid of device_t
......................................................................

mb/lenovo: Get rid of device_t

Use of device_t has been abandoned in ramstage.

Change-Id: Ic044fc074c43db683fcd85ce92a36a8c5a464a67
Signed-off-by: Elyes HAOUAS <ehaouas at noos.fr>
---
M src/mainboard/lenovo/g505s/mainboard.c
M src/mainboard/lenovo/g505s/mptable.c
M src/mainboard/lenovo/l520/mainboard.c
M src/mainboard/lenovo/s230u/mainboard.c
M src/mainboard/lenovo/t400/mainboard.c
M src/mainboard/lenovo/t420/mainboard.c
M src/mainboard/lenovo/t420s/mainboard.c
M src/mainboard/lenovo/t430/mainboard.c
M src/mainboard/lenovo/t430s/mainboard.c
M src/mainboard/lenovo/t520/mainboard.c
M src/mainboard/lenovo/t530/mainboard.c
M src/mainboard/lenovo/t60/mainboard.c
M src/mainboard/lenovo/x131e/mainboard.c
M src/mainboard/lenovo/x1_carbon_gen1/mainboard.c
M src/mainboard/lenovo/x200/mainboard.c
M src/mainboard/lenovo/x201/mainboard.c
M src/mainboard/lenovo/x220/mainboard.c
M src/mainboard/lenovo/x230/mainboard.c
M src/mainboard/lenovo/x60/mainboard.c
M src/mainboard/lenovo/z61t/mainboard.c
20 files changed, 30 insertions(+), 30 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/01/26101/1

diff --git a/src/mainboard/lenovo/g505s/mainboard.c b/src/mainboard/lenovo/g505s/mainboard.c
index a33c132..c9e00b6 100644
--- a/src/mainboard/lenovo/g505s/mainboard.c
+++ b/src/mainboard/lenovo/g505s/mainboard.c
@@ -29,7 +29,7 @@
 	lenovo_g505s_ec_init();
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	printk(BIOS_INFO, "Mainboard " CONFIG_MAINBOARD_PART_NUMBER " Enable.\n");
 
diff --git a/src/mainboard/lenovo/g505s/mptable.c b/src/mainboard/lenovo/g505s/mptable.c
index 39af326..a78c82e 100644
--- a/src/mainboard/lenovo/g505s/mptable.c
+++ b/src/mainboard/lenovo/g505s/mptable.c
@@ -145,7 +145,7 @@
 	/* on board NIC & Slot PCIE.  */
 
 	/* PCI slots */
-	device_t dev = dev_find_slot(0, PCI_DEVFN(0x14, 4));
+	struct device *dev = dev_find_slot(0, PCI_DEVFN(0x14, 4));
 	if (dev && dev->enabled) {
 		u8 bus_pci = dev->link_list->secondary;
 		/* PCI_SLOT 0. */
diff --git a/src/mainboard/lenovo/l520/mainboard.c b/src/mainboard/lenovo/l520/mainboard.c
index 526a173..db695b1 100644
--- a/src/mainboard/lenovo/l520/mainboard.c
+++ b/src/mainboard/lenovo/l520/mainboard.c
@@ -19,7 +19,7 @@
 #include <drivers/intel/gma/int15.h>
 #include <ec/lenovo/h8/h8.h>
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/s230u/mainboard.c b/src/mainboard/lenovo/s230u/mainboard.c
index a1b63cc..769fe3c 100644
--- a/src/mainboard/lenovo/s230u/mainboard.c
+++ b/src/mainboard/lenovo/s230u/mainboard.c
@@ -65,7 +65,7 @@
 	       fwvh >> 4, fwvh & 0x0f, fwvl >> 4, 0x41 + (fwvl & 0xf));
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	dev->ops->get_smbios_strings = mainboard_smbios_strings,
 
diff --git a/src/mainboard/lenovo/t400/mainboard.c b/src/mainboard/lenovo/t400/mainboard.c
index 87ed12e..b475e09 100644
--- a/src/mainboard/lenovo/t400/mainboard.c
+++ b/src/mainboard/lenovo/t400/mainboard.c
@@ -16,7 +16,7 @@
 #include <device/device.h>
 #include <drivers/intel/gma/int15.h>
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_CENTERING,
diff --git a/src/mainboard/lenovo/t420/mainboard.c b/src/mainboard/lenovo/t420/mainboard.c
index f3ca67b..6c85aba 100644
--- a/src/mainboard/lenovo/t420/mainboard.c
+++ b/src/mainboard/lenovo/t420/mainboard.c
@@ -19,7 +19,7 @@
 #include <drivers/intel/gma/int15.h>
 #include <ec/lenovo/h8/h8.h>
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/t420s/mainboard.c b/src/mainboard/lenovo/t420s/mainboard.c
index f3ca67b..6c85aba 100644
--- a/src/mainboard/lenovo/t420s/mainboard.c
+++ b/src/mainboard/lenovo/t420s/mainboard.c
@@ -19,7 +19,7 @@
 #include <drivers/intel/gma/int15.h>
 #include <ec/lenovo/h8/h8.h>
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/t430/mainboard.c b/src/mainboard/lenovo/t430/mainboard.c
index d18678b..99a5bd8 100644
--- a/src/mainboard/lenovo/t430/mainboard.c
+++ b/src/mainboard/lenovo/t430/mainboard.c
@@ -21,7 +21,7 @@
 {
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/t430s/mainboard.c b/src/mainboard/lenovo/t430s/mainboard.c
index f3ca67b..6c85aba 100644
--- a/src/mainboard/lenovo/t430s/mainboard.c
+++ b/src/mainboard/lenovo/t430s/mainboard.c
@@ -19,7 +19,7 @@
 #include <drivers/intel/gma/int15.h>
 #include <ec/lenovo/h8/h8.h>
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/t520/mainboard.c b/src/mainboard/lenovo/t520/mainboard.c
index 00f365b..bd4292a 100644
--- a/src/mainboard/lenovo/t520/mainboard.c
+++ b/src/mainboard/lenovo/t520/mainboard.c
@@ -21,7 +21,7 @@
 
 /* mainboard_enable is executed as first thing after
 enumerate_buses(). */
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/t530/mainboard.c b/src/mainboard/lenovo/t530/mainboard.c
index 0114e9b..29c15e0 100644
--- a/src/mainboard/lenovo/t530/mainboard.c
+++ b/src/mainboard/lenovo/t530/mainboard.c
@@ -22,7 +22,7 @@
 // mainboard_enable is executed as first thing after
 // enumerate_buses().
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/t60/mainboard.c b/src/mainboard/lenovo/t60/mainboard.c
index 153960a..167ffb2 100644
--- a/src/mainboard/lenovo/t60/mainboard.c
+++ b/src/mainboard/lenovo/t60/mainboard.c
@@ -39,10 +39,10 @@
 	return ARRAY_SIZE(cst_entries);
 }
 
-static void mainboard_init(device_t dev)
+static void mainboard_init(struct device *dev)
 {
 	struct southbridge_intel_i82801gx_config *config;
-	device_t idedev;
+	struct device *idedev;
 
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
@@ -74,7 +74,7 @@
 	ec_write(0x0c, inb(0x164c) & 8 ? 0x89 : 0x09);
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	dev->ops->init = mainboard_init;
 }
diff --git a/src/mainboard/lenovo/x131e/mainboard.c b/src/mainboard/lenovo/x131e/mainboard.c
index c68b956..1342aca 100644
--- a/src/mainboard/lenovo/x131e/mainboard.c
+++ b/src/mainboard/lenovo/x131e/mainboard.c
@@ -17,7 +17,7 @@
 #include <drivers/intel/gma/int15.h>
 #include <ec/lenovo/h8/h8.h>
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/x1_carbon_gen1/mainboard.c b/src/mainboard/lenovo/x1_carbon_gen1/mainboard.c
index a4f2b38..64cc15b 100644
--- a/src/mainboard/lenovo/x1_carbon_gen1/mainboard.c
+++ b/src/mainboard/lenovo/x1_carbon_gen1/mainboard.c
@@ -19,7 +19,7 @@
 #include <drivers/intel/gma/int15.h>
 #include <ec/lenovo/h8/h8.h>
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/x200/mainboard.c b/src/mainboard/lenovo/x200/mainboard.c
index 8acbb00..1510ab7 100644
--- a/src/mainboard/lenovo/x200/mainboard.c
+++ b/src/mainboard/lenovo/x200/mainboard.c
@@ -17,12 +17,12 @@
 #include <drivers/intel/gma/int15.h>
 #include <drivers/lenovo/lenovo.h>
 
-static void fill_ssdt(device_t device)
+static void fill_ssdt(struct device *device)
 {
 	drivers_lenovo_serial_ports_ssdt_generate("\\_SB.PCI0.LPCB", 0);
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_CENTERING,
diff --git a/src/mainboard/lenovo/x201/mainboard.c b/src/mainboard/lenovo/x201/mainboard.c
index 9ccf1d3..59add68 100644
--- a/src/mainboard/lenovo/x201/mainboard.c
+++ b/src/mainboard/lenovo/x201/mainboard.c
@@ -45,7 +45,7 @@
 	return ARRAY_SIZE(cst_entries);
 }
 
-static void mainboard_init(device_t dev)
+static void mainboard_init(struct device *dev)
 {
 	printk(BIOS_SPEW, "starting SPI configuration\n");
 
@@ -73,12 +73,12 @@
 	printk(BIOS_SPEW, "SPI configured\n");
 }
 
-static void fill_ssdt(device_t device)
+static void fill_ssdt(struct device *device)
 {
 	drivers_lenovo_serial_ports_ssdt_generate("\\_SB.PCI0.LPCB", 0);
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	u16 pmbase;
 
diff --git a/src/mainboard/lenovo/x220/mainboard.c b/src/mainboard/lenovo/x220/mainboard.c
index 0114e9b..29c15e0 100644
--- a/src/mainboard/lenovo/x220/mainboard.c
+++ b/src/mainboard/lenovo/x220/mainboard.c
@@ -22,7 +22,7 @@
 // mainboard_enable is executed as first thing after
 // enumerate_buses().
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/x230/mainboard.c b/src/mainboard/lenovo/x230/mainboard.c
index 0114e9b..29c15e0 100644
--- a/src/mainboard/lenovo/x230/mainboard.c
+++ b/src/mainboard/lenovo/x230/mainboard.c
@@ -22,7 +22,7 @@
 // mainboard_enable is executed as first thing after
 // enumerate_buses().
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
diff --git a/src/mainboard/lenovo/x60/mainboard.c b/src/mainboard/lenovo/x60/mainboard.c
index a0d4599..431a143 100644
--- a/src/mainboard/lenovo/x60/mainboard.c
+++ b/src/mainboard/lenovo/x60/mainboard.c
@@ -69,9 +69,9 @@
 	return ARRAY_SIZE(cst_entries);
 }
 
-static void mainboard_init(device_t dev)
+static void mainboard_init(struct device *dev)
 {
-	device_t idedev, sdhci_dev;
+	struct device *idedev, sdhci_dev;
 
 	ec_clr_bit(0x03, 2);
 
@@ -115,12 +115,12 @@
 	}
 }
 
-static void fill_ssdt(device_t device)
+static void fill_ssdt(struct device *device)
 {
 	drivers_lenovo_serial_ports_ssdt_generate("\\_SB.PCI0.LPCB", 1);
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	dev->ops->init = mainboard_init;
 	dev->ops->acpi_fill_ssdt_generator = fill_ssdt;
diff --git a/src/mainboard/lenovo/z61t/mainboard.c b/src/mainboard/lenovo/z61t/mainboard.c
index e5860ac..be4cf3c 100644
--- a/src/mainboard/lenovo/z61t/mainboard.c
+++ b/src/mainboard/lenovo/z61t/mainboard.c
@@ -39,10 +39,10 @@
 	return ARRAY_SIZE(cst_entries);
 }
 
-static void mainboard_init(device_t dev)
+static void mainboard_init(struct device *dev)
 {
 	struct southbridge_intel_i82801gx_config *config;
-	device_t idedev;
+	struct device *idedev;
 
 	install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS,
 					GMA_INT15_PANEL_FIT_DEFAULT,
@@ -74,7 +74,7 @@
 	ec_write(0x0c, inb(0x164c) & 8 ? 0x89 : 0x09);
 }
 
-static void mainboard_enable(device_t dev)
+static void mainboard_enable(struct device *dev)
 {
 	dev->ops->init = mainboard_init;
 }

-- 
To view, visit https://review.coreboot.org/26101
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic044fc074c43db683fcd85ce92a36a8c5a464a67
Gerrit-Change-Number: 26101
Gerrit-PatchSet: 1
Gerrit-Owner: Elyes HAOUAS <ehaouas at noos.fr>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20180504/eb917be2/attachment-0001.html>


More information about the coreboot-gerrit mailing list