Received: by 2002:a89:48b:0:b0:1f5:f2ab:c469 with SMTP id a11csp469054lqd; Wed, 24 Apr 2024 07:48:00 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXop/MefL9mOkFpw2ClWrdEYjDPX9K16gaNdWJbnZAFY+BxYwscfs8UwlYe5Lj6SJKN4MAWbPvpHd1Dxv7ppjBWvEiHzJIzuxGRMZjLXA== X-Google-Smtp-Source: AGHT+IGHWF1/vCxtTiOBT0mT2o5dKnRsD/GeTyQNQXA8qrGgPGadmHt9tFDWJxJxQhN5q4RFD8Me X-Received: by 2002:a05:690c:690f:b0:615:1527:aa2 with SMTP id if15-20020a05690c690f00b0061515270aa2mr2814361ywb.10.1713970079850; Wed, 24 Apr 2024 07:47:59 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713970079; cv=pass; d=google.com; s=arc-20160816; b=DU8rLCP8O5MX32GaXPfMTYhtncHtX8MqBgjBKYpkuSa41gQUrG0T/UmWCQYbcFvEZM HH4+raKr3Cbvo+6K4Tm2KNBamC6rUopeCwKGlDXUTXBUZLgVJI++TLWDGxwdHdQ+sT1H rCn6lSwNITbad+WkIko1k5Q1pri6i/1YouCKFX0g/jRcA/dbY/fpNqtAjf3fv2k/pIi/ vTAldP2UF1uzecxmHc6IWxwJVlgkOcL+7GZCL6rYP007ZIM9RS3T8q5+E3k0WbsdDU9Y /eLibVreP3UX0J+Dl+Z1NT+InbqEknVB99ODf+VkX78O1G46z5ktd7uSu3pKluu05+uq k5ww== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:autocrypt:content-language :from:references:cc:to:subject:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=rmBHxU+K5+JFdDXXWYzqD2OyvFTC6VOaZA7L4t5ci3I=; fh=Ab3ItkNw9l4jdj0J19UuB9MyQWLkiBM+bkPF4LjBBuc=; b=qevHyZ+T0JWUucWnRSLq5ZclaSLafEO7nqTFXPIydWBp4+/7aICSDOLlt5fF6C8+aP pBlmQnOb9LH93wfK1R7ZBLgMM9Qyi80+BHSsBkgLs43l1ubYx3SpXtgY/jO4deqn1oym aELM5ZHCom3Vp9M0SDMKAMrjXgV5BCOUeLwrV0ka6Bl13pANSJtd+avRWcy/Asfknflx 4dArbyP9QkRErBUWPEQ7C2r5jxwA6C2rV0LbgkA4tIh4cRyAmvPMYivLxFQ6dtiN0T9f Mc8872Pdc7qoWO+YMnbhI1RhPlYsql/uDY546GMsbzinuZyaUMHYxGbY3yacbOZU41eX a0jQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kZ53top6; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-157116-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-157116-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id p10-20020a05622a13ca00b00437846af0a5si15805607qtk.492.2024.04.24.07.47.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Apr 2024 07:47:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-157116-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kZ53top6; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-157116-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-157116-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 6EC001C24F3E for ; Wed, 24 Apr 2024 14:47:29 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B17E115ECFC; Wed, 24 Apr 2024 14:46:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="kZ53top6" Received: from mail-ed1-f44.google.com (mail-ed1-f44.google.com [209.85.208.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1B8191DFEB for ; Wed, 24 Apr 2024 14:46:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713969999; cv=none; b=B9bs74PkT+IK7jREQPTqIpkjo/pswUFTu9QRFr9PQb0m9xOsdhnJPxa5P3pa6rKBBABY5/2y3Xj3qvNsIPo0Sy4Xm8xg4Y3qh6pT5mei7lgVe83UbmpvbPEFoqaXnuHaTNhjk/mv9P0yirMibPE8al37OMnQcDCjs3IWGIFEHoI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713969999; c=relaxed/simple; bh=F+yMiTBe5/hoxx2NJhqcvizqF27UFcCyQ+BG9ETc4IQ=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=khilMTXOJ+tTde+x9BXVzG3rtN1PwkpHFhMnUQ5Ul6zW23VV7GwSMsoGYDXlIg/CfZuLG9phAyRCIM0dwrF5G54KEAzPRLOPypQpMStSMnHZdnGZSblcC3OH+kEyXqOWf19Piib/fV6xtccfvzZvhYZyJ+9CD4jvK+5qfDa2k6Y= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=kZ53top6; arc=none smtp.client-ip=209.85.208.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-ed1-f44.google.com with SMTP id 4fb4d7f45d1cf-56e69888a36so7114792a12.3 for ; Wed, 24 Apr 2024 07:46:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1713969996; x=1714574796; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:autocrypt:content-language :from:references:cc:to:subject:user-agent:mime-version:date :message-id:from:to:cc:subject:date:message-id:reply-to; bh=rmBHxU+K5+JFdDXXWYzqD2OyvFTC6VOaZA7L4t5ci3I=; b=kZ53top66Zq27EgqxWEwQMaDQDRwMN1S3bPquFH+UeSuyh3d8TuKrpV1lxdvNDmAYN cEfj+Ew2ZM+VT+Uznx7RadfgvDhnqTGrGVP9wQlmBgiTcsMWDa61cFMR8GIskc4EbnBc 48yaA9DfC7mpFaCOuZ4A6ZYKVNbO7HYLazC81IhXJ0NsJFC0L9Ra5MiI4llTKKxC6RFF zm0EUGVH6J3jeQCi7aA4hEaTioaDNXyWUshW+MT3ImY3YXmddaS/5Aw2ExIWmn/xJujv UJlZUsiV5yye4YwZiCby7hX6pU1Wt5rNMoaf1Ux7b3r1dw+UJ8zrY+tgJlToDm/AyMAI 09VA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713969996; x=1714574796; h=content-transfer-encoding:in-reply-to:autocrypt:content-language :from:references:cc:to:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=rmBHxU+K5+JFdDXXWYzqD2OyvFTC6VOaZA7L4t5ci3I=; b=Kx4qdiR/ncdmP7WjZAMf0m49CIjv0mLzMptiWadakM8SqCuxgDGTIr2lxnmrVtGYjx oTbyjM+1ylcxJxidvEXygbUmlVl2AHjgP57FvT/Bi1CBVSX9ZtV9g4Wt2DY3rk+Zo0wB iv7l6cPIk93tjTHa/vozymU+KKi5fyiUzSaUFJIXfVtVSrs9nJHLOEAuyJrsRfLml3vg lx3Cd3YTUtVbJhYGbrHjN8SUzcx+037IBapeG22saR3mzT919MZbElzi0CYjGFY5a+F2 uZfxGHewJ6uW//ShPxpbgw11wNqv9mx7gFV8YN1QB8SwckwoxXnzeVNAWYKtW13YhPF4 CNVQ== X-Forwarded-Encrypted: i=1; AJvYcCWrcnj5eV5XfEtu4Eb9Huy0XHE4tTglPaYspSV6CbdqtsBL90Q5jGu337JzACG+E2eHk3aJmwzTjoTl2xSY0yr+I4L5AhFvFvoY2v2V X-Gm-Message-State: AOJu0YwB+R+ztBqOGIUel/uRwX2PUVGAlH9RpgQvwmiu2FxXYxnOUrVh uNQPPangJ8PJbSroQ5OtOMHdQ7V3fDH3oAJaZle3ECg4WCpySHI0gLo1y0Ros/Y= X-Received: by 2002:a50:9b5b:0:b0:570:8d89:4c3f with SMTP id a27-20020a509b5b000000b005708d894c3fmr2047583edj.0.1713969996460; Wed, 24 Apr 2024 07:46:36 -0700 (PDT) Received: from [192.168.1.20] ([178.197.223.16]) by smtp.gmail.com with ESMTPSA id k13-20020a508acd000000b0056ff510c327sm8224276edk.94.2024.04.24.07.46.34 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 24 Apr 2024 07:46:35 -0700 (PDT) Message-ID: <0f8ba1b5-490e-4961-80e2-7942f66730ec@linaro.org> Date: Wed, 24 Apr 2024 16:46:34 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2] Bluetooth: qca: set power_ctrl_enabled on NULL returned by gpiod_get_optional() To: Bartosz Golaszewski , Marcel Holtmann , Luiz Augusto von Dentz Cc: linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski , Wren Turkal , Zijun Hu References: <20240424122932.79120-1-brgl@bgdev.pl> From: Krzysztof Kozlowski Content-Language: en-US Autocrypt: addr=krzysztof.kozlowski@linaro.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xeYJtjUH0ZX6ndJ33FJYf5V3yXqqjcZ30FgHzJCFUu JMp7PSyMPzpUXfU12yfcRYVEMQrmplNZssmYhiTeVicuOOypWugZKVLGNm0IweVCaZ/DJDIH gNbpvVwjcKYrx85m9cBVEBUGaQP6AT7qlVCkrf50v8bofSIyVa2xmubbAwwFA1oxoOusjPIE J3iadrwpFvsZjF5uHAKS+7wHLoW9hVzOnLbX6ajk5Hf8Pb1m+VH/E8bPBNNYKkfTtypTDUCj NYcd27tjnXfG+SDs/EXNUAIRefCyvaRG7oRYF3Ec+2RgQDRnmmjCjoQNbFrJvJkFHlPeHaeS BosGY+XWKydnmsfY7SSnjAzLUGAFhLd/XDVpb1Een2XucPpKvt9ORF+48gy12FA5GduRLhQU vK4tU7ojoem/G23PcowM1CwPurC8sAVsQb9KmwTGh7rVz3ks3w/zfGBy3+WmLg++C2Wct6nM Pd8/6CBVjEWqD06/RjI2AnjIq5fSEH/BIfXXfC68nMp9BZoy3So4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ZftdybIzpMZ5V9v45lUwmdnMrSzZVgC4jRGXzsU EViBQt2CopXtHtYfPAO5nAkIvKSNp3jmGxZw4aTc5xoAZBLo0OV+Ezo71pg3AYvq0a3/oGRG KQ06ztUMRrj8eVtpImjsWCd0bDWRaaR4vqhCHvAG9iWXZu4qh3ipie2Y0oSJygcZT7H3UZxq fyYKiqEmRuqsvv6dcbblD8ZLkz1EVZL6djImH5zc5x8qpVxlA0A0i23v5QvN00m6G9NFF0Le D2GYIS41Kv4Isx2dEFh+/Q== In-Reply-To: <20240424122932.79120-1-brgl@bgdev.pl> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 24/04/2024 14:29, Bartosz Golaszewski wrote: > From: Bartosz Golaszewski > > qcadev->susclk = devm_clk_get_optional(&serdev->dev, NULL); > if (IS_ERR(qcadev->susclk)) { > @@ -2355,10 +2360,13 @@ static int qca_serdev_probe(struct serdev_device *serdev) > qcadev->bt_en = devm_gpiod_get_optional(&serdev->dev, "enable", > GPIOD_OUT_LOW); > if (IS_ERR(qcadev->bt_en)) { > - dev_warn(&serdev->dev, "failed to acquire enable gpio\n"); > - power_ctrl_enabled = false; > + dev_err(&serdev->dev, "failed to acquire enable gpio\n"); > + return PTR_ERR(qcadev->bt_en); > } > > + if (!qcadev->bt_en) > + power_ctrl_enabled = false; This looks duplicated - you already have such check earlier. Best regards, Krzysztof