Skip to contentSkip to conversation

Patch "pinctrl: intel: merrifield: Add missed check in mrfld_config_set()" has been added to the 4.9-stable tree

PATCH [email protected] 1 participant 1 message Feb 4, 2017

Subsystems (4)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

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

pinctrl: intel: merrifield: Add missed check in mrfld_config_set()

to the 4.9-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:
pinctrl-intel-merrifield-add-missed-check-in-mrfld_config_set.patch
and it can be found in the queue-4.9 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From 19b26d92dfb70f56440c187a20c49102ab648b97 Mon Sep 17 00:00:00 2001

From: Andy Shevchenko <[email protected]>
Date: Tue, 24 Jan 2017 17:28:22 +0200
Subject: pinctrl: intel: merrifield: Add missed check in mrfld_config_set()

From: Andy Shevchenko <[email protected]>

commit 19b26d92dfb70f56440c187a20c49102ab648b97 upstream.

Not every pin can be configured. Add missed check to prevent access violation.

Fixes 4e80c8f50574 ("pinctrl: intel: Add Intel Merrifield pin controller support")
---
 drivers/pinctrl/intel/pinctrl-merrifield.c |    3 +++
 1 file changed, 3 insertions(+)
drivers/pinctrl/intel/pinctrl-merrifield.c +3 -0
@@ -794,6 +794,9 @@ static int mrfld_config_set(struct pinct
 	unsigned int i;
 	int ret;
 
+	if (!mrfld_buf_available(mp, pin))
+		return -ENOTSUPP;
+
 	for (i = 0; i < nconfigs; i++) {
 		switch (pinconf_to_config_param(configs[i])) {
 		case PIN_CONFIG_BIAS_DISABLE:

Patches currently in stable-queue which might be from [email protected] are

queue-4.9/pinctrl-baytrail-debounce-register-is-one-per-community.patch queue-4.9/pinctrl-intel-merrifield-add-missed-check-in-mrfld_config_set.patch