[i2c] [PATCH] Add support for the S-35390A RTC chip.

David Brownell david-b at pacbell.net
Sun Jan 6 23:25:37 CET 2008


On Sunday 06 January 2008, Byron Bradley wrote:
> David, the ENOCSI comment probably applies to your at24 eeprom driver
> too. I was wondering why that error code was chosen since other than
> "No CSI structure available" I couldn't find anything about it.

It was chosen for its uniqueness ... ideally each fault path has its
own fault code and (possibly debug-only) diagnostic.  When you get
a fault code from a driver, and there's only one place that's used,
it's a lot easier to know what went wrong than if the fault code is
(over)used in many places.

In fact it's common practice to adopt subsystem-specific conventions
about what a given errno value indicates.  Otherwise, almost every
fault observed would map to a small handful ... making them useless
for fault recovery logic, and at best problematic in terms of any
diagnostic utility.

- Dave




More information about the i2c mailing list