mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-31 04:01:48 -04:00
i2c: Add support for custom probe function
The probe method used by i2c_new_probed_device() may not be suitable for all cases. Let the caller provide its own, optional probe function. Signed-off-by: Jean Delvare <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
This commit is contained in:
parent
f1c2e33c29
commit
9a94241afc
11 changed files with 31 additions and 21 deletions
|
|
@ -322,10 +322,10 @@ do_attach( struct i2c_adapter *adapter )
|
|||
|
||||
memset(&info, 0, sizeof(struct i2c_board_info));
|
||||
strlcpy(info.type, "therm_ds1775", I2C_NAME_SIZE);
|
||||
i2c_new_probed_device(adapter, &info, scan_ds1775);
|
||||
i2c_new_probed_device(adapter, &info, scan_ds1775, NULL);
|
||||
|
||||
strlcpy(info.type, "therm_adm1030", I2C_NAME_SIZE);
|
||||
i2c_new_probed_device(adapter, &info, scan_adm1030);
|
||||
i2c_new_probed_device(adapter, &info, scan_adm1030, NULL);
|
||||
|
||||
if( x.thermostat && x.fan ) {
|
||||
x.running = 1;
|
||||
|
|
|
|||
Loading…
Reference in a new issue