Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp236685pxb; Wed, 11 Nov 2020 02:17:53 -0800 (PST) X-Google-Smtp-Source: ABdhPJwTp195K57nK++0wcEfZw30jyddHknZqOgT6r14V8hVBLzY8mkrRX96QPaiC7yUHcgf2CF7 X-Received: by 2002:a17:906:8c6:: with SMTP id o6mr23254123eje.230.1605089873714; Wed, 11 Nov 2020 02:17:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605089873; cv=none; d=google.com; s=arc-20160816; b=wElDDy6r4Dyc1BC8TXIPDHe3nkDiOeix49GtfJ7o+mmQWJHiHrk7HuV8Aa22dEcBsL 95M9NUPZXcDtVSkARQ1hBxtVXnK9OVblEHlUMChmkLfAsySWaikGzfY9kQ41rHQ0r86D lvyKdu0m3P16CMfFxBj+rhdFtrqSzmvqoH2rH11dzSKeVgwX9i8yzOfijKtliVeLHcV5 18mHeTXsCCVZPaIQoqAWOoTZKLIura+uTqqqhdI2M2779D69tjGYy3D0Z+xtUvVfh7ni N6oCztEd/KS68/LfDJTaA3UAw4+mPR38GChmQA7bZpeaiCnSkqaij6LmMMiA2Msvmh9/ B2iQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=fj/d+uUSa66ZXaIECxvpPkifnEUL90fECrea16eIp0M=; b=L/fTPtgsRbcrG9Zzh1hGiq3T5lkOCgi23EQO0VGe1ucdcLy/ZtDwrvgsJFLHdilkMV ziG3gbn/zbL7njDNQksRKVJ8i/EAFfhQFEr9kWId+/4M+6VgSO3VBKb2TNiV9wz1YA25 7Gm744ojHgD/sfmME55a9UEEHOLOpugnSvyzth4zbeViLvhqw0lTHK6He1Z9YDP33KhN jP4OYjQua+PbhMBhBLRAxWgoFzMjxZu58vgVcNB8W5xc5fAfii50ARm+8TP7aQKSVftT QiwxrHUN6LOL8JjxD0BCCeD6in3ksdrmtVhOS6xvHHut1n3To7nmXj/ytEcAeK03GsKP r8nQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="w/TRaMIC"; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y18si1206836edl.592.2020.11.11.02.17.30; Wed, 11 Nov 2020 02:17:53 -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=@kernel.org header.s=default header.b="w/TRaMIC"; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727253AbgKKKP7 (ORCPT + 99 others); Wed, 11 Nov 2020 05:15:59 -0500 Received: from mail.kernel.org ([198.145.29.99]:46362 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727017AbgKKKP7 (ORCPT ); Wed, 11 Nov 2020 05:15:59 -0500 Received: from mail-oo1-f46.google.com (mail-oo1-f46.google.com [209.85.161.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4D2EA20825 for ; Wed, 11 Nov 2020 10:15:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605089758; bh=fj/d+uUSa66ZXaIECxvpPkifnEUL90fECrea16eIp0M=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=w/TRaMICMK+LsuUIxKTT+0VMfl7UhviTUY8AbG2saPsB6F0YnX1CPDLgBHfOW7DT1 SdIKAeLjiGcBGfzZbioSFRel6QCaMQ9suSsk/fq5vdW7ZAJfnUgun9uSCSp/yYHfb2 4el+Q35N1YieGgcBmRuD7TiRFcE4FQTHYoyUsNpQ= Received: by mail-oo1-f46.google.com with SMTP id z14so298058oom.10 for ; Wed, 11 Nov 2020 02:15:58 -0800 (PST) X-Gm-Message-State: AOAM533UsIaabcOj5G23kmzaJhrFfpQaB5x2/N6Vdn6sjmq1yO7s2yXZ Hjc72Z2T8V2NCuIcixVyonReuzqLmNRwO1/qDkw= X-Received: by 2002:a4a:a217:: with SMTP id m23mr16529435ool.26.1605089757445; Wed, 11 Nov 2020 02:15:57 -0800 (PST) MIME-Version: 1.0 References: <20201110161338.18198-1-enric.balletbo@collabora.com> In-Reply-To: <20201110161338.18198-1-enric.balletbo@collabora.com> From: Arnd Bergmann Date: Wed, 11 Nov 2020 11:15:41 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2] mfd: syscon: Add syscon_regmap_lookup_by_phandle_optional() function. To: Enric Balletbo i Serra Cc: "linux-kernel@vger.kernel.org" , Collabora Kernel ML , Nicolas Boichat , Matthias Brugger , Arnd Bergmann , Lee Jones Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 10, 2020 at 5:13 PM 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 Reviewed-by: Arnd Bergmann