From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756151AbcKKIqP (ORCPT ); Fri, 11 Nov 2016 03:46:15 -0500 Received: from smtp.csie.ntu.edu.tw ([140.112.30.61]:59304 "EHLO smtp.csie.ntu.edu.tw" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755792AbcKKIqO (ORCPT ); Fri, 11 Nov 2016 03:46:14 -0500 MIME-Version: 1.0 In-Reply-To: <20161111083852.yacy33g6pag6ucon@lukather> References: <20161111024455.16883-1-wens@csie.org> <20161111024455.16883-4-wens@csie.org> <20161111083852.yacy33g6pag6ucon@lukather> From: Chen-Yu Tsai Date: Fri, 11 Nov 2016 16:45:49 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 3/3] pinctrl: sunxi: Make sunxi_pconf_group_set use sunxi_pconf_reg helper To: Maxime Ripard Cc: Chen-Yu Tsai , Linus Walleij , "linux-gpio@vger.kernel.org" , linux-arm-kernel , linux-kernel , linux-sunxi Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 11, 2016 at 4:38 PM, Maxime Ripard wrote: > On Fri, Nov 11, 2016 at 10:44:55AM +0800, Chen-Yu Tsai wrote: >> The sunxi_pconf_reg helper introduced in the last patch gives us the >> chance to rework sunxi_pconf_group_set to have it match the structure >> of sunxi_pconf_(group_)get and make it easier to understand. >> >> For each config to set, it: >> >> 1. checks if the parameter is supported. >> 2. checks if the argument is within limits. >> 3. converts argument to the register value. >> 4. writes to the register with spinlock held. >> >> As a result the function now blocks unsupported config parameters, >> instead of silently ignoring them. >> >> Signed-off-by: Chen-Yu Tsai > > Acked-by: Maxime Ripard > > But I think the config variable removal should be part of patch 2, as > discussed there. OK. I think that makes sense. Re-reading my patches, I can't figure out, which patch I meant for it to go in. :( I'll send out a v3. ChenYu