Patch "Input: iqs7222 - set all ULP entry masks by default" has been added to the 6.0-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    Input: iqs7222 - set all ULP entry masks by default

to the 6.0-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     input-iqs7222-set-all-ulp-entry-masks-by-default.patch
and it can be found in the queue-6.0 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 6938214051b65478eef0a3df50597f234f3b10a2
Author: Jeff LaBundy <jeff@xxxxxxxxxxx>
Date:   Thu Sep 8 14:24:35 2022 -0700

    Input: iqs7222 - set all ULP entry masks by default
    
    [ Upstream commit d56111ed58482de0045e1e1201122e6e71516945 ]
    
    Some devices expose an ultra-low-power (ULP) mode entry mask for
    each channel. If the mask is set, the device cannot enter ULP so
    long as the corresponding channel remains in an active state.
    
    The vendor has advised setting the mask for any disabled channel.
    To accommodate this suggestion, initially set all masks and then
    clear them only if specified in the device tree.
    
    Fixes: e505edaedcb9 ("Input: add support for Azoteq IQS7222A/B/C")
    Signed-off-by: Jeff LaBundy <jeff@xxxxxxxxxxx>
    Link: https://lore.kernel.org/r/20220908131548.48120-8-jeff@xxxxxxxxxxx
    Signed-off-by: Dmitry Torokhov <dmitry.torokhov@xxxxxxxxx>
    Stable-dep-of: 2f6fd2329789 ("Input: iqs7222 - protect against undefined slider size")
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/input/misc/iqs7222.c b/drivers/input/misc/iqs7222.c
index b2e8097a2e6d..8b3362169265 100644
--- a/drivers/input/misc/iqs7222.c
+++ b/drivers/input/misc/iqs7222.c
@@ -1771,11 +1771,9 @@ static int iqs7222_parse_chan(struct iqs7222_private *iqs7222, int chan_index)
 	if (!chan_node)
 		return 0;
 
-	if (dev_desc->allow_offset) {
-		sys_setup[dev_desc->allow_offset] |= BIT(chan_index);
-		if (fwnode_property_present(chan_node, "azoteq,ulp-allow"))
-			sys_setup[dev_desc->allow_offset] &= ~BIT(chan_index);
-	}
+	if (dev_desc->allow_offset &&
+	    fwnode_property_present(chan_node, "azoteq,ulp-allow"))
+		sys_setup[dev_desc->allow_offset] &= ~BIT(chan_index);
 
 	chan_setup[0] |= IQS7222_CHAN_SETUP_0_CHAN_EN;
 
@@ -2206,6 +2204,9 @@ static int iqs7222_parse_all(struct iqs7222_private *iqs7222)
 	u16 *sys_setup = iqs7222->sys_setup;
 	int error, i;
 
+	if (dev_desc->allow_offset)
+		sys_setup[dev_desc->allow_offset] = U16_MAX;
+
 	if (dev_desc->event_offset)
 		sys_setup[dev_desc->event_offset] = IQS7222_EVENT_MASK_ATI;
 



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux