X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=drivers%2Frtc%2Frtc-pcf8583.c;h=556d0e7da35bd04dc44df605ca22e77f95793d25;hb=444ad82bc3eaa554be40d22dc248e58aeefd54d9;hp=d48b033745868bb28f801b957dc874d3328acd78;hpb=cb2ebc59ff52cee770cfd6ba5f23a6cc3c214648;p=linux-2.6 diff --git a/drivers/rtc/rtc-pcf8583.c b/drivers/rtc/rtc-pcf8583.c index d48b033745..556d0e7da3 100644 --- a/drivers/rtc/rtc-pcf8583.c +++ b/drivers/rtc/rtc-pcf8583.c @@ -332,6 +332,9 @@ static int pcf8583_probe(struct i2c_adapter *adap, int addr, int kind) } }; + if (!i2c_check_functionality(adap, I2C_FUNC_I2C)) + return 0; + pcf = kzalloc(sizeof(*pcf), GFP_KERNEL); if (!pcf) return -ENOMEM;