device/smbus_ops.c: Get rid of device_t
Use of `device_t` has been abandoned in ramstage. Change-Id: I5eb858df7b69a7177564c883b81177ffadc63691 Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr> Reviewed-on: https://review.coreboot.org/26005 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Patrick Georgi <pgeorgi@google.com>
This commit is contained in:
parent
e18cbea8f5
commit
2f119a31f7
|
@ -20,7 +20,7 @@
|
||||||
#include <device/device.h>
|
#include <device/device.h>
|
||||||
#include <device/smbus.h>
|
#include <device/smbus.h>
|
||||||
|
|
||||||
struct bus *get_pbus_smbus(device_t dev)
|
struct bus *get_pbus_smbus(struct device *dev)
|
||||||
{
|
{
|
||||||
struct bus *const pbus = i2c_link(dev);
|
struct bus *const pbus = i2c_link(dev);
|
||||||
if (!pbus->dev->ops->ops_smbus_bus) {
|
if (!pbus->dev->ops->ops_smbus_bus) {
|
||||||
|
@ -40,7 +40,7 @@ struct bus *get_pbus_smbus(device_t dev)
|
||||||
*
|
*
|
||||||
* @param dev TODO.
|
* @param dev TODO.
|
||||||
*/
|
*/
|
||||||
int smbus_set_link(device_t dev)
|
int smbus_set_link(struct device *dev)
|
||||||
{
|
{
|
||||||
struct bus *pbus_a[4]; // 4 level mux only. Enough?
|
struct bus *pbus_a[4]; // 4 level mux only. Enough?
|
||||||
struct bus *pbus = dev->bus;
|
struct bus *pbus = dev->bus;
|
||||||
|
@ -75,7 +75,7 @@ int smbus_set_link(device_t dev)
|
||||||
return -1; \
|
return -1; \
|
||||||
}
|
}
|
||||||
|
|
||||||
int smbus_block_read(device_t dev, u8 cmd, u8 bytes, u8 *buffer)
|
int smbus_block_read(struct device *dev, u8 cmd, u8 bytes, u8 *buffer)
|
||||||
{
|
{
|
||||||
CHECK_PRESENCE(block_read);
|
CHECK_PRESENCE(block_read);
|
||||||
|
|
||||||
|
@ -83,7 +83,7 @@ int smbus_block_read(device_t dev, u8 cmd, u8 bytes, u8 *buffer)
|
||||||
bytes, buffer);
|
bytes, buffer);
|
||||||
}
|
}
|
||||||
|
|
||||||
int smbus_block_write(device_t dev, u8 cmd, u8 bytes, const u8 *buffer)
|
int smbus_block_write(struct device *dev, u8 cmd, u8 bytes, const u8 *buffer)
|
||||||
{
|
{
|
||||||
CHECK_PRESENCE(block_write);
|
CHECK_PRESENCE(block_write);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue