Attention is currently required from: Alexander Couzens, Evgeny Zinoviev.
Elyes Haouas has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/83860?usp=email )
Change subject: [test C23] i945: Use nullptr instead of NULL ......................................................................
[test C23] i945: Use nullptr instead of NULL
Modern C provides nullptr constant. Use it unstead of macro.
Change-Id: I7d47e692a33d739345a81f589d4329a31beeb8c5 Signed-off-by: Elyes Haouas ehaouas@noos.fr --- M src/mainboard/apple/macbook21/mptable.c M src/mainboard/asus/p2b/variants/p2b-d/mptable.c M src/mainboard/asus/p2b/variants/p2b-ds/mptable.c M src/mainboard/getac/p470/mptable.c M src/mainboard/ibase/mb899/mptable.c M src/mainboard/intel/d945gclf/mptable.c M src/mainboard/kontron/986lcd-m/mainboard.c M src/mainboard/kontron/986lcd-m/mptable.c M src/mainboard/lenovo/t60/mptable.c M src/mainboard/lenovo/x60/mptable.c M src/mainboard/roda/rk886ex/mptable.c M src/northbridge/intel/i945/Kconfig M src/northbridge/intel/i945/northbridge.c M src/northbridge/intel/i945/raminit.c 14 files changed, 17 insertions(+), 16 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/60/83860/1
diff --git a/src/mainboard/apple/macbook21/mptable.c b/src/mainboard/apple/macbook21/mptable.c index fcf46a2..38916d3 100644 --- a/src/mainboard/apple/macbook21/mptable.c +++ b/src/mainboard/apple/macbook21/mptable.c @@ -15,7 +15,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/asus/p2b/variants/p2b-d/mptable.c b/src/mainboard/asus/p2b/variants/p2b-d/mptable.c index e6b5459..e631a5b 100644 --- a/src/mainboard/asus/p2b/variants/p2b-d/mptable.c +++ b/src/mainboard/asus/p2b/variants/p2b-d/mptable.c @@ -14,7 +14,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* External Intel 82093AA IOAPIC. */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/asus/p2b/variants/p2b-ds/mptable.c b/src/mainboard/asus/p2b/variants/p2b-ds/mptable.c index f06fc60..2350fc1 100644 --- a/src/mainboard/asus/p2b/variants/p2b-ds/mptable.c +++ b/src/mainboard/asus/p2b/variants/p2b-ds/mptable.c @@ -14,7 +14,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* External Intel 82093AA IOAPIC. */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/getac/p470/mptable.c b/src/mainboard/getac/p470/mptable.c index d7a4af6..6743bda 100644 --- a/src/mainboard/getac/p470/mptable.c +++ b/src/mainboard/getac/p470/mptable.c @@ -15,7 +15,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/ibase/mb899/mptable.c b/src/mainboard/ibase/mb899/mptable.c index bb43796..e34c723 100644 --- a/src/mainboard/ibase/mb899/mptable.c +++ b/src/mainboard/ibase/mb899/mptable.c @@ -8,7 +8,7 @@ static void *smp_write_config_table(void *v) { struct mp_config_table *mc; - struct device *riser = NULL, *firewire = NULL; + struct device *riser = nullptr, *firewire = nullptr; int firewire_bus = 0, riser_bus = 0, isa_bus;
mc = (void *)(((char *)v) + SMP_FLOATING_TABLE_LEN); @@ -34,7 +34,7 @@ printk(BIOS_SPEW, "Riser bus is %x\n", riser_bus); }
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/intel/d945gclf/mptable.c b/src/mainboard/intel/d945gclf/mptable.c index 7ab47b4..6c9d12b 100644 --- a/src/mainboard/intel/d945gclf/mptable.c +++ b/src/mainboard/intel/d945gclf/mptable.c @@ -15,7 +15,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/kontron/986lcd-m/mainboard.c b/src/mainboard/kontron/986lcd-m/mainboard.c index bd50fc3..56c9ffa 100644 --- a/src/mainboard/kontron/986lcd-m/mainboard.c +++ b/src/mainboard/kontron/986lcd-m/mainboard.c @@ -141,7 +141,7 @@ continue; printk(BIOS_DEBUG, "Disabling Ethernet NIC #%d\n", i); dev = pcidev_on_root(28, i - 1); - if (dev == NULL) { + if (dev == nullptr) { printk(BIOS_ERR, "Disabling Ethernet NIC: Cannot find 00:1c.%d!\n", i - 1); diff --git a/src/mainboard/kontron/986lcd-m/mptable.c b/src/mainboard/kontron/986lcd-m/mptable.c index 5ee3288..b112ac0 100644 --- a/src/mainboard/kontron/986lcd-m/mptable.c +++ b/src/mainboard/kontron/986lcd-m/mptable.c @@ -7,7 +7,7 @@ static void *smp_write_config_table(void *v) { struct mp_config_table *mc; - struct device *riser = NULL, *firewire = NULL; + struct device *riser = nullptr, *firewire = nullptr; int firewire_bus = 0, riser_bus = 0, isa_bus;
mc = (void *)(((char *)v) + SMP_FLOATING_TABLE_LEN); @@ -30,7 +30,7 @@ riser_bus = riser->downstream->secondary; }
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/lenovo/t60/mptable.c b/src/mainboard/lenovo/t60/mptable.c index f640085..aa83105 100644 --- a/src/mainboard/lenovo/t60/mptable.c +++ b/src/mainboard/lenovo/t60/mptable.c @@ -15,7 +15,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/lenovo/x60/mptable.c b/src/mainboard/lenovo/x60/mptable.c index 73e9c1b..12e88a4 100644 --- a/src/mainboard/lenovo/x60/mptable.c +++ b/src/mainboard/lenovo/x60/mptable.c @@ -15,7 +15,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/mainboard/roda/rk886ex/mptable.c b/src/mainboard/roda/rk886ex/mptable.c index 3ce1cbc..a9bfe26 100644 --- a/src/mainboard/roda/rk886ex/mptable.c +++ b/src/mainboard/roda/rk886ex/mptable.c @@ -15,7 +15,7 @@
smp_write_processors(mc);
- mptable_write_buses(mc, NULL, &isa_bus); + mptable_write_buses(mc, nullptr, &isa_bus);
/* I/O APICs: APIC ID Version State Address */ u8 ioapic_id = smp_write_ioapic_from_hw(mc, IO_APIC_ADDR); diff --git a/src/northbridge/intel/i945/Kconfig b/src/northbridge/intel/i945/Kconfig index 32eff1a..12187b6 100644 --- a/src/northbridge/intel/i945/Kconfig +++ b/src/northbridge/intel/i945/Kconfig @@ -10,6 +10,7 @@ select HAVE_VGA_TEXT_FRAMEBUFFER if MAINBOARD_DO_NATIVE_VGA_INIT select USE_DDR2 select NEED_SMALL_2MB_PAGE_TABLES + select ALLOW_UNSUPPORTED_C23
if NORTHBRIDGE_INTEL_I945
diff --git a/src/northbridge/intel/i945/northbridge.c b/src/northbridge/intel/i945/northbridge.c index 82f3843..a268c5b 100644 --- a/src/northbridge/intel/i945/northbridge.c +++ b/src/northbridge/intel/i945/northbridge.c @@ -74,14 +74,14 @@ return "PCI0";
if (!is_pci_dev_on_bus(dev, 0)) - return NULL; + return nullptr;
switch (dev->path.pci.devfn) { case PCI_DEVFN(0, 0): return "MCHC"; }
- return NULL; + return nullptr; }
void northbridge_write_smram(u8 smram) diff --git a/src/northbridge/intel/i945/raminit.c b/src/northbridge/intel/i945/raminit.c index a37754b..b664fbe 100644 --- a/src/northbridge/intel/i945/raminit.c +++ b/src/northbridge/intel/i945/raminit.c @@ -1142,7 +1142,7 @@ int i; size_t cum0, cum1, tolud, tom, pci_mmio_size; const struct device *dev; - const struct northbridge_intel_i945_config *cfg = NULL; + const struct northbridge_intel_i945_config *cfg = nullptr;
printk(BIOS_DEBUG, "Setting RAM size...\n");