From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 461D3C6FA91 for ; Tue, 20 Sep 2022 18:10:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230084AbiITSKn (ORCPT ); Tue, 20 Sep 2022 14:10:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41516 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231334AbiITSKT (ORCPT ); Tue, 20 Sep 2022 14:10:19 -0400 Received: from smtp1.axis.com (smtp1.axis.com [195.60.68.17]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 130A62AF for ; Tue, 20 Sep 2022 11:10:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axis.com; q=dns/txt; s=axis-central1; t=1663697418; x=1695233418; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=PpGa4JUsfG70iHiyHmFuSmcm699LUitaSlS44lXU4uY=; b=CdUkLBH5PMNJ2dnK7ICIWSfF/3XE4jfTE9jGdR4K+tgpEigt9NLujI6a UM0wTAT9ZjJg2PUIW5DsA+8XYtxQQ0IhtmJeNm6sGjUHK3dqAOGSN9ZKN oofVQfCHWpASFhQ0VYh2yEgqs+EUpQJwYhTLf2UkxImwSPqCRXWA6VVku 24ZWEC68uCALeWyxUnRFIj74jH3zRINMfCnFiKPRcraQ4Tr/gJ1BJA0BG l+/IOa58GOV5Yu8lvBsvipJGHEw5N5oIzHqesnQUv8v6QCKx64MrBfUKc 6JNqCSvcgVbtT7OGc5jTlc6Xt/sdJ6A/WQ4yPNLhJnm7MUh5L93hj78pA g==; From: =?UTF-8?q?M=C3=A5rten=20Lindahl?= To: Jonathan Cameron , Lars-Peter Clausen CC: Paul Cercueil , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , , , =?UTF-8?q?M=C3=A5rten=20Lindahl?= Subject: [PATCH 0/3] Add basic attributes for vcnl4040 Date: Tue, 20 Sep 2022 20:09:55 +0200 Message-ID: <20220920180958.2308229-1-marten.lindahl@axis.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org Hi! Currently there is no way for userspace to make any configuration of the VCNL4040 sensors, but only the sensor readings are exported in sysfs. To support basic control of the sensors such as enable/disable and setting integration time value, sysfs attributes for this needs to be exported. To begin with the runtime power management turns both sensors (ALS, and PS) on before reading the sensor register values and then switching them off again. But when doing so it writes the whole register instead of just switching the power on/off bit. This needs to be fixed in order to make other persistent configurations. Kind regards Mårten Lindahl Mårten Lindahl (3): iio: light: vcnl4000: Preserve conf bits when toggle power iio: light: vcnl4000: Add enable attributes for vcnl4040 iio: light: vcnl4000: Add ps_it attributes for vcnl4040 drivers/iio/light/vcnl4000.c | 205 ++++++++++++++++++++++++++++++++++- 1 file changed, 200 insertions(+), 5 deletions(-) -- 2.30.2