On Wed, 20 Aug 2014, Ari Sundholm wrote: > - if (sscanf(buf, "%i", &mode) != 1 || (mode != 2 || mode != 1)) > + if (sscanf(buf, "%i", &mode) != 1 && (mode != 2 || mode != 1)) > return -EINVAL;
Note that the condition still looks wrong even after the revert, as (mode != 2 || mode != 1) is always true. Anybody guess what the actual intent was? Best regards, Ari Sundholm asund...@cs.hut.fi -- To unsubscribe from this list: send the line "unsubscribe platform-driver-x86" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html