Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp1034765pxb; Fri, 13 Nov 2020 02:24:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJzzqeC178CV+HZ0aF5hQ2Y/+8rqRyBo5v5HxgVU1IPlMUq6IOqecf0zbuWqzKFg9cZLXQ4t X-Received: by 2002:a05:6402:3d9:: with SMTP id t25mr1758437edw.338.1605263096463; Fri, 13 Nov 2020 02:24:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605263096; cv=none; d=google.com; s=arc-20160816; b=waKR+soJyJvKhRus98mivYGWC/yWscc7xDemHF2LL/7+mxxelzJ9363DcQvQqqCaW+ 8KjiAFsxKMgC/VcZZZs6i1DoyJvGXrwQgSZpybat48JhQeZ4IZz6Gyw2pJGyzRMHsR0o KXW2nQcfwLK55qRKXSVIzXM1SrBeccZV3BXMSw8/QQ3rMyWzbWMYSJXq8BzqeNysrzBB VFI5QL01fR7eqKvswYvdJmm07ipxRvfYLdXVawR+p3oRlX3Mgy8JlbZHBQbmt1eTDhTg 13PvYGNs0LYtr4F6dT5GzNeQJxzO4oboGIn+gGvvvAekM41NJgrj7F++vjtIRmPKKNFL YREg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=RmkrxeBx46DhTuid3vYjjgytEVotpngZcVJnlj9M3tM=; b=DNcBCrP8wMXSlRPG6Xs3t4LdAC3/GjIrdyfUGPRmT24jfaJQXvYFFQaWny84oO/T/f gX3bpUIMhMlsZvAyBeSp/0vDT18+lwE5f8F3+EnpnCr0mahiISJOsQ/3+jwWXAVmce8I rpOnDFtEZBv6BCF9K167pFWKPGrNnOcUiZ3dQGdiK7rGBjK3ue/U61pT4IqZ7wqklQ5d P2w/ksDi9ffR0mcUt4w7h+eHaqmSZMI9V3EvzJAnk0Je7nM1H3Y4l4VEjjadgZk69r+l j3BhBH/+1sbCs01DErNqodVgaJWPdBP///dL3QqZ9S3eb4yljL5JO808eh151EqF0en7 eyGA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="nCt/I4kd"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u13si5371502ejt.298.2020.11.13.02.24.30; Fri, 13 Nov 2020 02:24:56 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="nCt/I4kd"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726309AbgKMKTv (ORCPT + 99 others); Fri, 13 Nov 2020 05:19:51 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47376 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726184AbgKMKTv (ORCPT ); Fri, 13 Nov 2020 05:19:51 -0500 Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F115CC0613D1 for ; Fri, 13 Nov 2020 02:19:43 -0800 (PST) Received: by mail-wm1-x341.google.com with SMTP id 23so7763411wmg.1 for ; Fri, 13 Nov 2020 02:19:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to; bh=RmkrxeBx46DhTuid3vYjjgytEVotpngZcVJnlj9M3tM=; b=nCt/I4kddXnWLS5DWKyA7EfwbtbE5EeCRPUdXTBaB7mouJ0mlP4lfIhY+KtGNrpoCs UqjT0hnPJcP+sZECJ1txcVZPMgOVQDeDqH4hd2pmqYFKFw72eCq8XFQyhdBzaT9/lQVf WlZhTUpe6T6c4w+7uqyKd81LL0q4hYfa6+2pnU7BYjf00DGkapnc5A8P/4J2neyhdzgr wOk+7L527/5n5Y3Bo1cRiWe2ssF0sIJDQ2v0AI9LLAN7gpAiY0jZUTE1yyravaB1gx5b swWQpOrzoo50CHAGhru818syrdIKbRuLISNol8KcoMHOVWtRWAbX+hL/sXiBt7tJrIJx x2JQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to; bh=RmkrxeBx46DhTuid3vYjjgytEVotpngZcVJnlj9M3tM=; b=j88DsIpRcdcLbMOjQG96bES3YVYhECf6svK+UOHCJDkdwY56vXvdOGx9ZeZL8jeiKG GGVhOrlviSRDEnc8Fs7GIgpxkea+sTr/C3BTI/h6ZX1fz1OfjBVjQTXkFCwH9zYOIxF5 qUGFRuvUVRlsBUQbd+fyyrinXj+djyEqFnpZnF1stlLPHRHLPW2K8WK8dlebvNURLs10 SomPsRU1MW0jIiPFO3RDAHi8UQbzFAPy1BTeI4+ZWCM9FFqjW68UsuCb48pg7lf33EOR ndcuewL0X28IJsSdKuB76xhxYzCNf3tHcwgXRPTQ++Ww3mHpzAIY4f0kBMopeADkx8rL L1wg== X-Gm-Message-State: AOAM532dT+YO73TS9oSYEs0eLOEJxmNIO0NNk3FS3ckafeW0nzLUAvgM wJGSw5qAK9/M8QUxe/rZo9Zn3A== X-Received: by 2002:a1c:7d12:: with SMTP id y18mr1727783wmc.103.1605262782647; Fri, 13 Nov 2020 02:19:42 -0800 (PST) Received: from dell ([91.110.221.159]) by smtp.gmail.com with ESMTPSA id h62sm10243357wrh.82.2020.11.13.02.19.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Nov 2020 02:19:41 -0800 (PST) Date: Fri, 13 Nov 2020 10:19:40 +0000 From: Lee Jones To: Enric Balletbo i Serra Cc: linux-kernel@vger.kernel.org, Collabora Kernel ML , Nicolas Boichat , Matthias Brugger , Arnd Bergmann Subject: Re: [PATCH v2] mfd: syscon: Add syscon_regmap_lookup_by_phandle_optional() function. Message-ID: <20201113101940.GH3718728@dell> References: <20201110161338.18198-1-enric.balletbo@collabora.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20201110161338.18198-1-enric.balletbo@collabora.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 10 Nov 2020, Enric Balletbo i Serra wrote: > This adds syscon_regmap_lookup_by_phandle_optional() function to get an > optional regmap. > > It behaves the same as syscon_regmap_lookup_by_phandle() except where > there is no regmap phandle. In this case, instead of returning -ENODEV, > the function returns NULL. This makes error checking simpler when the > regmap phandle is optional. > > Suggested-by: Nicolas Boichat > Signed-off-by: Enric Balletbo i Serra > Reviewed-by: Matthias Brugger > --- > > Changes in v2: > - Add Matthias r-b tag. > - Add the explanation from the patch description to the code. > - Return NULL instead of -ENOTSUPP when regmap helpers are not enabled. > > drivers/mfd/syscon.c | 18 ++++++++++++++++++ > include/linux/mfd/syscon.h | 11 +++++++++++ > 2 files changed, 29 insertions(+) Applied, thanks. -- Lee Jones [李琼斯] Senior Technical Lead - Developer Services Linaro.org │ Open source software for Arm SoCs Follow Linaro: Facebook | Twitter | Blog