From 449b1a1f6650d4491c74d15f6037a28091d9ae5d Mon Sep 17 00:00:00 2001 From: Marius Strobl Date: Sat, 16 Jun 2007 23:07:53 +0000 Subject: [PATCH] Remove the code for displaying the OFW hostid during boot for the reasons outlined in the comment removed along with it, because the OFW hostid has no real meaning for FreeBSD and mainly so the OFW hostid is not confused with the FreeBSD hostid. --- sys/sparc64/sparc64/eeprom.c | 26 +------------------------- 1 file changed, 1 insertion(+), 25 deletions(-) diff --git a/sys/sparc64/sparc64/eeprom.c b/sys/sparc64/sparc64/eeprom.c index d6186ba45f2a..84c0272b2d91 100644 --- a/sys/sparc64/sparc64/eeprom.c +++ b/sys/sparc64/sparc64/eeprom.c @@ -68,7 +68,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include @@ -78,8 +77,6 @@ __FBSDID("$FreeBSD$"); #include "clock_if.h" -#define IDPROM_OFFSET 40 - static devclass_t eeprom_devclass; static device_probe_t eeprom_probe; @@ -124,8 +121,7 @@ eeprom_attach(device_t dev) struct mk48txx_softc *sc; struct resource *res; struct timespec ts; - uint32_t h; - int error, i, rid; + int error, rid; sc = device_get_softc(dev); @@ -173,26 +169,6 @@ eeprom_attach(device_t dev) goto fail_res; } - /* - * Get the hostid from the NVRAM. This serves no real purpose other - * than being able to display it below as not all sparc64 models - * have an `eeprom' device and even some that do store the hostid - * elsewhere. The hostid in the NVRAM of the MK48Txx reads all zero - * on the latter models. A generic way to retrieve the hostid is to - * use the `idprom' node. - */ - mtx_lock(&sc->sc_mtx); - h = bus_space_read_1(sc->sc_bst, sc->sc_bsh, sc->sc_nvramsz - - IDPROM_OFFSET + offsetof(struct idprom, id_machine)) << 24; - for (i = 0; i < 3; i++) { - h |= bus_space_read_1(sc->sc_bst, sc->sc_bsh, sc->sc_nvramsz - - IDPROM_OFFSET + offsetof(struct idprom, id_hostid[i])) << - ((2 - i) * 8); - } - mtx_unlock(&sc->sc_mtx); - if (h != 0) - device_printf(dev, "hostid %x\n", (u_int)h); - if (bootverbose) { mk48txx_gettime(dev, &ts); device_printf(dev, "current time: %ld.%09ld\n", (long)ts.tv_sec,