Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp1195045pxb; Sat, 9 Jan 2021 10:44:13 -0800 (PST) X-Google-Smtp-Source: ABdhPJw+LrGOazGI4wpKuDmpzxHTh3BEF/ReQnNqjBOWyfTL86t1JN9Rm9u3F7eocZoFHLLJ4qVw X-Received: by 2002:a50:f0dc:: with SMTP id a28mr9246861edm.291.1610217853118; Sat, 09 Jan 2021 10:44:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610217853; cv=none; d=google.com; s=arc-20160816; b=HeDmB9eyKFOEBbi54m6OOORFyR012sSYd9ixxaTRcO8N5uIlGtaTdO+6e28q610qo/ MRb6U/WL9n2dE8iSyztZZgH6gZ7PXTKClw1oGuMPqMq2JaJhPpXNYgMVZCgDpDavNRD1 TzIRxjPhBEmsphw6WB3yhMSrTE2MFJp5RGAWah7DQJmv1SHqlpRXtWHO1S74d+VaTYr2 qeq0P5/VPa8GEf8WeSfXQu1xhWLoHbkvprYo40kbnOLVM2d9llt3dp8kZu6FPsvmK6dW 1Lgw8tSCwLq1Q9MFi92j18H4TpxLxjKhRodrgaplKpq0box3n9JNRox8kubtQ89hl5Jl qgeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=BOcllbr10NVxX8OyFF583Mi2sPtEyaEd4G2uz33GE+Q=; b=eAfOd6P8l/K6GrK2LVJjHhTizkNJWx51DFsfCrhrENvNJiz5ZAy/TzeOIiXoRxodr9 R09sQFKwqKshYk4ydmBc43gYkuszV/XwduSLAf8g6mhjroswEf6xeXSnqv4g3P8T9sSP R2/+wwW3830RqHLLaFK3VJWoxUPkl/BEFUlOcuBRJhB4GKk7h9DzFlFbXeEF2Am5Nuw/ zHCe4IVypd3qDArAqPYDC7b86vzwq0PyyOQzUkSUoLmV040LggIk4CCoTB/RokGJZtJl mRsRS9wBKN6s7bq9xyMlLqPGFYwvOa2n2uZIjdnzA2YrJ7afAPMBonzYPg5vDfYhEdcX N1WA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s11si5028621edw.280.2021.01.09.10.43.49; Sat, 09 Jan 2021 10:44:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726198AbhAISmN (ORCPT + 99 others); Sat, 9 Jan 2021 13:42:13 -0500 Received: from mail.kernel.org ([198.145.29.99]:45782 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725956AbhAISmN (ORCPT ); Sat, 9 Jan 2021 13:42:13 -0500 Received: from archlinux (cpc108967-cmbg20-2-0-cust86.5-4.cable.virginm.net [81.101.6.87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 131C923A04; Sat, 9 Jan 2021 18:41:30 +0000 (UTC) Date: Sat, 9 Jan 2021 18:41:27 +0000 From: Jonathan Cameron To: "Ye, Xiang" Cc: jikos@kernel.org, srinivas.pandruvada@linux.intel.com, linux-input@vger.kernel.org, linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4 0/3] add custom hinge sensor support Message-ID: <20210109184127.48ac58c3@archlinux> In-Reply-To: <20201231024640.GA5718@host> References: <20201215054444.9324-1-xiang.ye@intel.com> <20201230120517.622d3351@archlinux> <20201231024640.GA5718@host> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 31 Dec 2020 10:46:40 +0800 "Ye, Xiang" wrote: > On Wed, Dec 30, 2020 at 12:05:17PM +0000, Jonathan Cameron wrote: > > On Tue, 15 Dec 2020 13:44:41 +0800 > > Ye Xiang wrote: > > > > > Here we register one iio device with three channels which present angle for > > > hinge, keyboard and screen. > > > > > > This driver works on devices with Intel integrated sensor hub, where > > > hinge sensor is presented using a custom sensor usage id. > > > > > > Here the angle is presented in degrees, which is converted to radians. > > > > Other than those minor bits I'm happy to fix up in patch 2, this looks > > good to me. However, I'll need a Jiri Ack for the hid parts before > > I apply it. We are are early in this cycle, so no great rush given > > the usual xmas slow down! > > Ok, let's wait Jiri to review the hid parts. Thanks for the help. Series applied with the changes mentioned in review of patch 2. Applied to the togreg branch of iio.git and pushed out as testing for the various autobuilders to poke at it at and see if they can find anything I missed. Thanks, Jonathan > > Thanks > Ye Xiang > > > > > > > > Changes since v3: > > > - hid-sensor-custom: remove sensor_inst::custom_pdev_exposed. > > > - hid-sensor-custom: use static buf, w_buf to avoid using goto in > > > get_known_custom_sensor_index. > > > - hid-sensor-custom-intel-hinge: use devm_ prefix function instead. > > > - sysfs-bus-iio: put in_anglY_raw together with in_angl_raw. > > > > > > Changes since v2: > > > - use 1 iio device instead of 3 for hinge sensor. > > > - use indexed channel instead of modified channel and added channel > > > labels. > > > - remove 2,3 patch in last version, add a document patch to describe the > > > hinge channels. > > > - hid-sensor-custom: use meaningful return value in > > > get_known_custom_sensor_index and checked in call side. > > > - hid-sensor-ids.h: use HID_USAGE_SENSOR_DATA_FIELD_CUSTOM_VALUE(x) to > > > define custom sensor value. > > > > > > Changes since v1: > > > - fixed errors reported by lkp > > > > > > Ye Xiang (3): > > > HID: hid-sensor-custom: Add custom sensor iio support > > > iio: hid-sensors: Add hinge sensor driver > > > iio:Documentation: Add documentation for hinge sensor channels > > > > > > Documentation/ABI/testing/sysfs-bus-iio | 11 + > > > drivers/hid/hid-sensor-custom.c | 143 +++++++ > > > .../hid-sensors/hid-sensor-attributes.c | 2 + > > > drivers/iio/position/Kconfig | 16 + > > > drivers/iio/position/Makefile | 1 + > > > .../position/hid-sensor-custom-intel-hinge.c | 391 ++++++++++++++++++ > > > include/linux/hid-sensor-ids.h | 14 + > > > 7 files changed, 578 insertions(+) > > > create mode 100644 drivers/iio/position/hid-sensor-custom-intel-hinge.c > > > > >