Skip to content
Snippets Groups Projects
  • Jean Delvare's avatar
    41101a33
    i2c-algo-bit: Don't resched on clock stretching · 41101a33
    Jean Delvare authored
    
    Clock stretching is not supposed to last long, so asking to be
    rescheduled while waiting for the clock line to be released by a slave
    makes little sense. Odds are that the clock line will long have been
    released when we run again, so we will have lost time and may even
    get an SMBus timeout because of this.
    
    So just busy-wait in that case. This also participates in the effort
    to make i2c-algo-bit usable in contexts that can't sleep.
    
    Signed-off-by: default avatarJean Delvare <khali@linux-fr.org>
    Cc: Ben Skeggs <bskeggs@redhat.com>
    41101a33
    History
    i2c-algo-bit: Don't resched on clock stretching
    Jean Delvare authored
    
    Clock stretching is not supposed to last long, so asking to be
    rescheduled while waiting for the clock line to be released by a slave
    makes little sense. Odds are that the clock line will long have been
    released when we run again, so we will have lost time and may even
    get an SMBus timeout because of this.
    
    So just busy-wait in that case. This also participates in the effort
    to make i2c-algo-bit usable in contexts that can't sleep.
    
    Signed-off-by: default avatarJean Delvare <khali@linux-fr.org>
    Cc: Ben Skeggs <bskeggs@redhat.com>
Code owners
Assign users and groups as approvers for specific file changes. Learn more.