Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934230AbbLRBHH (ORCPT ); Thu, 17 Dec 2015 20:07:07 -0500 Received: from mail-ig0-f196.google.com ([209.85.213.196]:33857 "EHLO mail-ig0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933306AbbLRBHF (ORCPT ); Thu, 17 Dec 2015 20:07:05 -0500 MIME-Version: 1.0 In-Reply-To: <1450399868.5427.11.camel@linux.intel.com> References: <1450399868.5427.11.camel@linux.intel.com> Date: Thu, 17 Dec 2015 17:07:03 -0800 Message-ID: Subject: Re: iio/hid-sensor-accel-3d: no output from /dev/iio:device*? From: Nish Aravamudan To: Srinivas Pandruvada Cc: Jiri Kosina , Jonathan Cameron , Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald , linux-input@vger.kernel.org, linux-iio@vger.kernel.org, "linux-kernel@vger.kernel.org" , Crt Mori Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2152 Lines: 49 On Thu, Dec 17, 2015 at 4:51 PM, Srinivas Pandruvada wrote: > On Thu, 2015-12-17 at 15:38 -0800, Nish Aravamudan wrote: >> [Starting a new thread from https://lkml.org/lkml/2015/12/15/663, as >> now my laptop is displaying values in the sysfs *raw* files.] >> >> So I'm trying to understand exactly how the hid-sensor-accel-3d >> driver works. >> >> If I turn up debugging, when I `cat >> /sys/bus/iio/devices/device*/*raw*`, I see "iio iio:device3: >> accel_3d_proc_event" and I think that means that >> hid_sensor_push_data() is getting called. >> >> But read()'s on /dev/iio:device3 never produces anything, which is >> what iio-sensor-proxy uses to translate events to dbus. >> >> Is it expected that the dev-node is "silent"? Just trying to >> understand if an extension to the driver to support a chardev based >> output is appropriate, or if iio-sensor-proxy needs to be changed to >> handle this device. > > You are saying there is some regression. This used to work and now it > doesn't work. Is raw values are displayed correctly, when you do "cat"? > If cat of raw values is working then power on of sensors is working. Sorry, I was unclear. I don't know if this is a regression. I can try going back to an older kernel to see if the /dev/iio:device* files produced any output. Yes, the *raw* files in sysfs are producing output, that is changing as I move the laptop around. But the /dev/ nodes seem to produce no output (I'm still reading through the driver code to understand where that data should be coming from. > Turn on HID debug prints. If it is regression we can do git bisect. > Any ACPI or PM changes can break this. Usually there will be GPIOs > which will be involved in power on, where ACPI comes into play. This > will be done by i2c-hid. There are some prints in i2c-hid which can be > enabled also. Ok, I will try this, as well. -Nish -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/