sensor: fix mpu6880_acc.c waring.
authorguoyi <gy@rock-chips.com>
Wed, 14 Jan 2015 07:05:07 +0000 (15:05 +0800)
committerguoyi <gy@rock-chips.com>
Wed, 14 Jan 2015 07:05:07 +0000 (15:05 +0800)
drivers/input/sensors/accel/mpu6880_acc.c

index 767ed4341e0bf7cb7e43af0cf01d803bdc8ca6cb..0b5ca796aff0786a2087ef3503fb2c3db9be578a 100644 (file)
@@ -50,7 +50,7 @@ static int sensor_active(struct i2c_client *client, int enable, int rate)
                status = BIT_ACCEL_STBY;        
                sensor->ops->ctrl_data |= status;       
                //gyroºÍacc¶¼²»¹¤×÷ʱ£¬Ä£¿é½øÈëÐÝÃß
-               if(sensor->ops->ctrl_data & (BIT_ACCEL_STBY | BIT_GYRO_STBY) != 0)
+               if(sensor->ops->ctrl_data && (BIT_ACCEL_STBY | BIT_GYRO_STBY) != 0)
                {
                        pwrm1 |= MPU6880_PWRM1_SLEEP;
                }