Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756371AbcJGJIV convert rfc822-to-8bit (ORCPT ); Fri, 7 Oct 2016 05:08:21 -0400 Received: from smtp.exceet.ch ([77.245.33.226]:50854 "EHLO smtp.exceet.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754585AbcJGJIL (ORCPT ); Fri, 7 Oct 2016 05:08:11 -0400 From: Schrempf Frieder To: "robh@kernel.org" CC: "dmitry.torokhov@gmail.com" , "pawel.moll@arm.com" , "ijc+devicetree@hellion.org.uk" , "galak@codeaurora.org" , "luis@debethencourt.com" , "linux-input@vger.kernel.org" , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "Schrempf Frieder" Subject: [PATCH v2 0/3] input: pwm-beeper: add feature to set volume level Thread-Topic: [PATCH v2 0/3] input: pwm-beeper: add feature to set volume level Thread-Index: AQHSIHpSg/4myVNeQEiFU4W6ezHvWw== Date: Fri, 7 Oct 2016 09:08:08 +0000 Message-ID: <1475831223-6006-1-git-send-email-frieder.schrempf@exceet.de> References: In-Reply-To: Accept-Language: de-DE, en-US Content-Language: de-DE X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [178.2.219.242] x-tm-as-product-ver: SMEX-11.0.0.4255-8.000.1202-22622.006 x-tm-as-result: No--35.311100-5.000000-31 x-tm-as-user-approved-sender: No x-tm-as-user-blocked-sender: No Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1041 Lines: 28 Make the driver accept switching volume levels via sysfs. This can be helpful if the beep/bell sound intensity needs to be adapted to the environment of the device. The number of volume levels available and their values can be specified via device tree (similar to pwm-backlight). The volume adjustment is done by changing the duty cycle of the pwm signal. Changes in v2: - split into 3 separate patches - make volume devicetree properties optional - tested with Linux 4.7.4 Frieder Schrempf (3): input: pwm-beeper: add feature to set volume via sysfs input: pwm-beeper: add documentation for volume devicetree bindings input: pwm-beeper: add devicetree bindings to set volume levels .../ABI/testing/sysfs-class-input-pwm-beeper | 17 +++ .../devicetree/bindings/input/pwm-beeper.txt | 22 ++++ drivers/input/misc/pwm-beeper.c | 118 ++++++++++++++++++++- 3 files changed, 155 insertions(+), 2 deletions(-) create mode 100644 Documentation/ABI/testing/sysfs-class-input-pwm-beeper -- 1.9.1