Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/iicbus/lm75.c
Show First 20 Lines • Show All 153 Lines • ▼ Show 20 Lines | |||||
static int | static int | ||||
lm75_probe(device_t dev) | lm75_probe(device_t dev) | ||||
{ | { | ||||
struct lm75_softc *sc; | struct lm75_softc *sc; | ||||
sc = device_get_softc(dev); | sc = device_get_softc(dev); | ||||
sc->sc_hwtype = HWTYPE_LM75; | sc->sc_hwtype = HWTYPE_LM75; | ||||
#ifdef FDT | #ifdef FDT | ||||
if (!ofw_bus_is_compatible(dev, "national,lm75")) | if (!ofw_bus_is_compatible(dev, "national,lm75") && | ||||
!ofw_bus_is_compatible(dev, "ti,lm75")) | |||||
return (ENXIO); | return (ENXIO); | ||||
#endif | #endif | ||||
device_set_desc(dev, "LM75 temperature sensor"); | device_set_desc(dev, "LM75 temperature sensor"); | ||||
return (BUS_PROBE_GENERIC); | return (BUS_PROBE_GENERIC); | ||||
} | } | ||||
static int | static int | ||||
▲ Show 20 Lines • Show All 409 Lines • Show Last 20 Lines |