Home
last modified time | relevance | path

Searched refs:smbus (Results 1 – 25 of 63) sorted by relevance

123

/openbmc/linux/drivers/i2c/busses/
H A Di2c-pasemi-core.c45 static inline void reg_write(struct pasemi_smbus *smbus, int reg, int val) in reg_write() argument
47 dev_dbg(smbus->dev, "smbus write reg %x val %08x\n", reg, val); in reg_write()
48 iowrite32(val, smbus->ioaddr + reg); in reg_write()
51 static inline int reg_read(struct pasemi_smbus *smbus, int reg) in reg_read() argument
54 ret = ioread32(smbus->ioaddr + reg); in reg_read()
55 dev_dbg(smbus->dev, "smbus read reg %x val %08x\n", reg, ret); in reg_read()
59 #define TXFIFO_WR(smbus, reg) reg_write((smbus), REG_MTXFIFO, (reg)) argument
60 #define RXFIFO_RD(smbus) reg_read((smbus), REG_MRXFIFO) argument
62 static void pasemi_reset(struct pasemi_smbus *smbus) in pasemi_reset() argument
64 u32 val = (CTL_MTR | CTL_MRR | (smbus->clk_div & CTL_CLK_M)); in pasemi_reset()
[all …]
H A Di2c-amd8111.c68 static int amd_ec_wait_write(struct amd_smbus *smbus) in amd_ec_wait_write() argument
72 while ((inb(smbus->base + AMD_EC_SC) & AMD_EC_SC_IBF) && --timeout) in amd_ec_wait_write()
76 dev_warn(&smbus->dev->dev, in amd_ec_wait_write()
84 static int amd_ec_wait_read(struct amd_smbus *smbus) in amd_ec_wait_read() argument
88 while ((~inb(smbus->base + AMD_EC_SC) & AMD_EC_SC_OBF) && --timeout) in amd_ec_wait_read()
92 dev_warn(&smbus->dev->dev, in amd_ec_wait_read()
100 static int amd_ec_read(struct amd_smbus *smbus, unsigned char address, in amd_ec_read() argument
105 status = amd_ec_wait_write(smbus); in amd_ec_read()
108 outb(AMD_EC_CMD_RD, smbus->base + AMD_EC_CMD); in amd_ec_read()
110 status = amd_ec_wait_write(smbus); in amd_ec_read()
[all …]
H A Di2c-nforce2.c74 #define NVIDIA_SMB_PRTCL (smbus->base + 0x00) /* protocol, PEC */
75 #define NVIDIA_SMB_STS (smbus->base + 0x01) /* status */
76 #define NVIDIA_SMB_ADDR (smbus->base + 0x02) /* address */
77 #define NVIDIA_SMB_CMD (smbus->base + 0x03) /* command */
78 #define NVIDIA_SMB_DATA (smbus->base + 0x04) /* 32 data registers */
79 #define NVIDIA_SMB_BCNT (smbus->base + 0x24) /* number of data
81 #define NVIDIA_SMB_STATUS_ABRT (smbus->base + 0x3c) /* register used to
84 #define NVIDIA_SMB_CTRL (smbus->base + 0x3e) /* control register */
136 struct nforce2_smbus *smbus = adap->algo_data; in nforce2_abort() local
155 struct nforce2_smbus *smbus = adap->algo_data; in nforce2_check_status() local
[all …]
H A Di2c-pasemi-platform.c19 struct pasemi_smbus smbus; member
32 data->smbus.clk_div = DIV_ROUND_UP(clk_rate, 16 * frequency); in pasemi_platform_i2c_calc_clk_div()
33 if (data->smbus.clk_div < 4) in pasemi_platform_i2c_calc_clk_div()
34 return dev_err_probe(data->smbus.dev, -EINVAL, in pasemi_platform_i2c_calc_clk_div()
37 if (data->smbus.clk_div > 0xff) in pasemi_platform_i2c_calc_clk_div()
38 return dev_err_probe(data->smbus.dev, -EINVAL, in pasemi_platform_i2c_calc_clk_div()
49 struct pasemi_smbus *smbus; in pasemi_platform_i2c_probe() local
59 smbus = &data->smbus; in pasemi_platform_i2c_probe()
60 smbus->dev = dev; in pasemi_platform_i2c_probe()
62 smbus->ioaddr = devm_platform_ioremap_resource(pdev, 0); in pasemi_platform_i2c_probe()
[all …]
H A Di2c-pasemi-pci.c28 struct pasemi_smbus *smbus; in pasemi_smb_pci_probe() local
36 smbus = devm_kzalloc(&dev->dev, sizeof(*smbus), GFP_KERNEL); in pasemi_smb_pci_probe()
37 if (!smbus) in pasemi_smb_pci_probe()
40 smbus->dev = &dev->dev; in pasemi_smb_pci_probe()
43 smbus->clk_div = CLK_100K_DIV; in pasemi_smb_pci_probe()
49 smbus->hw_rev = PASEMI_HW_REV_PCI; in pasemi_smb_pci_probe()
55 smbus->ioaddr = pcim_iomap(dev, 0, 0); in pasemi_smb_pci_probe()
56 if (!smbus->ioaddr) in pasemi_smb_pci_probe()
59 smbus->adapter.class = I2C_CLASS_HWMON | I2C_CLASS_SPD; in pasemi_smb_pci_probe()
60 error = pasemi_i2c_common_probe(smbus); in pasemi_smb_pci_probe()
[all …]
H A Di2c-pasemi-core.h24 int pasemi_i2c_common_probe(struct pasemi_smbus *smbus);
/openbmc/openbmc/meta-openembedded/meta-python/recipes-devtools/python/python3-smbus/
H A D0001-Use-setuptools-as-distutils-is-deprecated.patch11 py-smbus/setup.py | 2 +-
14 diff --git a/py-smbus/setup.py b/py-smbus/setup.py
16 --- a/py-smbus/setup.py
17 +++ b/py-smbus/setup.py
24 setup( name="smbus",
/openbmc/openbmc/meta-openembedded/meta-python/recipes-devtools/python/
H A Dpython3-smbus2_0.5.0.bb1 SUMMARY = "Drop-in replacement for smbus-cffi/smbus-python in pure Python"
2 DESCRIPTION = "smbus2 is a drop-in replacement for smbus-cffi/smbus-python in pure Python"
H A Dpython3-smbus_4.3.bb3 LIC_FILES_CHKSUM = "file://py-smbus/smbusmodule.c;beginline=1;endline=18;md5=46e424fb045901ab25e0f9…
16 SETUPTOOLS_SETUP_PATH = "${S}/py-smbus"
/openbmc/qemu/hw/i2c/
H A Dpm_smbus.c74 I2CBus *bus = s->smbus; in smb_transaction()
134 s->smb_blkdata = i2c_recv(s->smbus); in smb_transaction()
281 ret = smbus_write_block(s->smbus, smb_addr, cmd, s->smb_data, in smb_ioport_writeb()
297 s->smb_blkdata = i2c_recv(s->smbus); in smb_ioport_writeb()
298 i2c_nack(s->smbus); in smb_ioport_writeb()
299 i2c_end_transfer(s->smbus); in smb_ioport_writeb()
308 s->smb_blkdata = i2c_recv(s->smbus); in smb_ioport_writeb()
324 i2c_end_transfer(s->smbus); in smb_ioport_writeb()
481 smb->smbus = i2c_init_bus(parent, "i2c"); in pm_smbus_init()
H A Dsmbus_eeprom.c165 void smbus_eeprom_init_one(I2CBus *smbus, uint8_t address, uint8_t *eeprom_buf) in DEFINE_TYPES()
173 qdev_realize_and_unref(dev, (BusState *)smbus, &error_fatal); in DEFINE_TYPES()
176 void smbus_eeprom_init(I2CBus *smbus, int nb_eeprom, in smbus_eeprom_init() argument
189 smbus_eeprom_init_one(smbus, 0x50 + i, in smbus_eeprom_init()
/openbmc/linux/Documentation/devicetree/bindings/hwmon/
H A Dstts751.txt8 - smbus-timeout-disable: when set, the smbus timeout function will be disabled
H A Dmax6697.txt20 - smbus-timeout-disable
60 smbus-timeout-disable;
/openbmc/linux/drivers/i2c/
H A DMakefile8 i2c-core-objs := i2c-core-base.o i2c-core-smbus.o
13 obj-$(CONFIG_I2C_SMBUS) += i2c-smbus.o
/openbmc/qemu/hw/pci-host/
H A Darticia.c44 bitbang_i2c_interface smbus; member
71 s->gpio |= bitbang_i2c_set(&s->smbus, BITBANG_I2C_SDA, in articia_gpio_write()
76 s->gpio |= bitbang_i2c_set(&s->smbus, BITBANG_I2C_SCL, in articia_gpio_write()
174 bitbang_i2c_init(&s->smbus, i2c_init_bus(dev, "smbus")); in articia_realize()
/openbmc/qemu/hw/mips/
H A Dfuloong2e.c222 I2CBus *smbus; in mips_fuloong2e_init() local
308 smbus = I2C_BUS(qdev_get_child_bus(dev, "i2c")); in mips_fuloong2e_init()
322 smbus_eeprom_init_one(smbus, 0x50, spd_data); in mips_fuloong2e_init()
/openbmc/openbmc/meta-inventec/meta-common/recipes-inventec/packagegroups/
H A Dpackagegroup-obmc-apps.bbappend4 RDEPENDS:${PN}-extras += " python3-smbus"
/openbmc/linux/Documentation/i2c/
H A Ddev-interface.rst28 #include <i2c/smbus.h>
151 You can do SMBus level transactions (see documentation file smbus-protocol.rst
201 performs an SMBus transaction using i2c-core-smbus.c:i2c_smbus_xfer().
214 i2c-core-smbus.c:i2c_smbus_xfer() calls either
216 i2c-core-smbus.c:i2c_smbus_xfer_emulated() which in turn calls
H A Dindex.rst15 smbus-protocol
/openbmc/qemu/include/hw/i2c/
H A Dpm_smbus.h10 I2CBus *smbus; member
/openbmc/openbmc/meta-inventec/meta-transformers/recipes-phosphor/image/
H A Dobmc-phosphor-image.bbappend7 OBMC_IMAGE_EXTRA_INSTALL:append = " python3-smbus"
/openbmc/openbmc/meta-raspberrypi/recipes-devtools/python/
H A Dpython3-adafruit-pureio_1.1.9.bb1 …ons) access to Linux IO including I2C and SPI. Drop in replacement for smbus and spidev modules…
/openbmc/qemu/hw/arm/
H A Dnpcm7xx.c439 for (i = 0; i < ARRAY_SIZE(s->smbus); i++) { in npcm7xx_init()
440 object_initialize_child(obj, "smbus[*]", &s->smbus[i], in npcm7xx_init()
616 QEMU_BUILD_BUG_ON(ARRAY_SIZE(npcm7xx_smbus_addr) != ARRAY_SIZE(s->smbus)); in npcm7xx_realize()
617 for (i = 0; i < ARRAY_SIZE(s->smbus); i++) { in npcm7xx_realize()
618 Object *obj = OBJECT(&s->smbus[i]); in npcm7xx_realize()
/openbmc/linux/drivers/input/mouse/
H A Dcyapa.c170 bool smbus = false; in cyapa_get_state() local
190 if (cyapa->smbus && (error == -ETIMEDOUT || error == -ENXIO)) { in cyapa_get_state()
194 smbus = true; in cyapa_get_state()
226 !smbus && even_addr) { in cyapa_get_state()
237 if (!smbus) { in cyapa_get_state()
251 } while (--retries > 0 && !smbus); in cyapa_get_state()
1272 cyapa->smbus = true; in cyapa_probe()
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-bsp/i2cdev/
H A Di2cdev_git.bb11 file://libi2cdev/smbus.c;beginline=9;endline=22;md5=d9a0de5a611b960fa75912ded6c60096 \

123