From: H Hartley Sweeten Date: Tue, 6 Oct 2009 04:43:42 +0000 (-0700) Subject: Input: rotary_encoder - fix relative axis support X-Git-Tag: v2.6.32-rc4~12^2~5 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=06ee3d3c254a8e8abb9549cd228325114f596e5c;p=~emulex%2Finfiniband.git Input: rotary_encoder - fix relative axis support When the rotart_encoder driver is used to report relative axis information the "steps" in the platform data could be missing since it's not relevant. Signed-off-by: H Hartley Sweeten Acked-by: Daniel Mack Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/misc/rotary_encoder.c b/drivers/input/misc/rotary_encoder.c index c806fbf1e17..3b9f588fc74 100644 --- a/drivers/input/misc/rotary_encoder.c +++ b/drivers/input/misc/rotary_encoder.c @@ -106,8 +106,8 @@ static int __devinit rotary_encoder_probe(struct platform_device *pdev) struct input_dev *input; int err; - if (!pdata || !pdata->steps) { - dev_err(&pdev->dev, "invalid platform data\n"); + if (!pdata) { + dev_err(&pdev->dev, "missing platform data\n"); return -ENOENT; }