Giter Club home page Giter Club logo

i2c-acpi-sbus's Introduction

i2c-acpi-sbus

ACPI SBUS i2c device driver.

The SBUS ACPI device implements an SMBus device, slightly simplified from the similar device implemented by the i2c-i801 driver. I could not find any documentation but the supported methods are straightforward to understand:

SSXB - send byte
    Arg0: address << 1
    Arg1: data
    Return: 0 on failure, 1, on success

SRXB - receive byte
    Arg0: (address << 1) | 0x01

SWRB - write byte
    Arg0: address << 1
    Arg1: command
    Arg2: data
    Return: 0 on failure, 1, on success

SRDB - read byte
    Arg0: (address << 1) | 0x01
    Arg1: command
    Return: 0xffff on failure, the read byte otherwise

SWRW - write word
    Arg0: address << 1
    Arg1: command
    Arg2: data
    Return: 0 on failure, 1, on success

SRDW - read word
    Arg0: (address << 1) | 0x01
    Arg1: command
    Return: 0xffffffff on failure, the read word otherwise

SBLW - write block data
    Arg0: address << 1
    Arg1: command
    Arg2: data - data[0] is the number of bytes that follow
    Return: 0 on failure, 1, on success

SBLR - read block data
    Arg0: (address << 1) | 0x01
    Arg1: command
    Return: 0 on failure, the read data otherwise

When reading data, the ACPI code internally or's the address with 0x01, but to be safe this is done by the driver as well.

There seems to be no consensus on whether SWRW/SRDW are read in little-endian or big-endian, as both variants appear in the wild.

i2c-acpi-sbus's People

Contributors

dtbartle avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

pali rsaliu

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.