Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2604587pxb; Sun, 24 Jan 2021 13:17:33 -0800 (PST) X-Google-Smtp-Source: ABdhPJwdQHeZrbm1UXQ//hyjGtx9wXPabt9ylkl+8lqw91ql/vvvVISXkJHZ8HRvnyYNgbIg+LOz X-Received: by 2002:aa7:c84b:: with SMTP id g11mr258189edt.169.1611523053141; Sun, 24 Jan 2021 13:17:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611523053; cv=none; d=google.com; s=arc-20160816; b=HyEdfXcGGIqTGdwO9Qf5AJ+RkZ1WVJE/MGoZ+DKfK94JvXRpInmelRfTTgBIMx5qzb LcoXLw4DKQbuHjHr8pPwyjrx7kkQ/FinF9UAZ6Y8otQjHfNaYYYoGB9Z2zgILNjQ81Gj WMOEScgOP04WufCVBO9YvajmFKCrG5gtxwzwe+pYcJJdNO7KOTvbb6TcOJ6PNtUgw1hN gSlSbzM9flYpq6mlNSlh78VnnBKK2jnKtYH15DFf/LcQEEL4nqp2l2OE2zIU33Njef4k /8cTd8b4f8QOugcVVxVoYbzYJJjKNIM4yQRTJyfYWxGsdbLLGCXtS3I3ea9Snk2oPp2z gMFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=Kv9jicTdTocjJxmYHF8RW7pmq0CcKS9rS4Zkv6lNt9I=; b=oMpj0YIw0KnmSeSeNzrQOcZv44nGj06BHYoz/70iklwgwYn/swyrpkuGpUZWDRmO9x U1dnchSR8GuGBvKTo5XhYrRL6xbG8xbGq7gL2qyiTyZnz47WytAbsNxXYu4dswZuNZcp GCxQFnxnbL3lUVVguO6tk2H21kSHB4Su4wGTxqOP1sPZ5Hrp5fN7XcOsHiByQLFti9CG aqgMC4AAjjsefYoUASfAjERgFGo3VPMcCpjxOsGb7acByufD1aFlATcibLh8fNo22Z1R Zeyl8xTUQTB89zQiiGV2yAgLtzjvIDsS68U5TOEtNmidIgMonnHY2oSnlJlR8N9dHPuk e6qQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=YhoMIAc4; 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=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q26si6588776edr.555.2021.01.24.13.16.59; Sun, 24 Jan 2021 13:17:33 -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=@redhat.com header.s=mimecast20190719 header.b=YhoMIAc4; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726149AbhAXVOq (ORCPT + 99 others); Sun, 24 Jan 2021 16:14:46 -0500 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:29573 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725969AbhAXVOq (ORCPT ); Sun, 24 Jan 2021 16:14:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1611522798; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Kv9jicTdTocjJxmYHF8RW7pmq0CcKS9rS4Zkv6lNt9I=; b=YhoMIAc4hoUmDr7vKTGi2sPUonh16zXcooQLuAJlDGQgwWuKbf0dsPQbsikjcslBD1/dM0 8B0MpZo/k1ISQJagsaFaguZq2/AQonrdWYMXaQ1neRujBa42wfOdYUoZfdoR94pkkbMoy7 PgDzox8930TwMTte5xuz/svaKWvdvp0= Received: from mail-ed1-f69.google.com (mail-ed1-f69.google.com [209.85.208.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-447-zNNMy-oAOIa68JVMLz9fDw-1; Sun, 24 Jan 2021 16:13:16 -0500 X-MC-Unique: zNNMy-oAOIa68JVMLz9fDw-1 Received: by mail-ed1-f69.google.com with SMTP id j11so5485085edy.20 for ; Sun, 24 Jan 2021 13:13:16 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=Kv9jicTdTocjJxmYHF8RW7pmq0CcKS9rS4Zkv6lNt9I=; b=qYK+rFgA9oZEwEJkzY1TRdr0tzdLEo1CCpoRkDKcrRl1qSJdxfU1ng9DhkXg9AkgO3 K6jNccPrRCtd1zmHH3qeIYHFpGNcJO1lseoQzYn0D5wbAEzRvyp65ch9MZ3mqNSgYoXC zqH3bsdMpM1dvM2pBI3fQUWnrQTkHM0FInqbD5jARPbN4MqCC1ZvsiSPgu+x5b16yTSS lEu1Z2eq9wcINUdfXUdD7RdQFkLg2a9J78HjChVhBpi4/bl+6fRntQ0jye1xgfmduE7A QsSNZUKTqKKuoRpLnn6IinXBczI5OKf5SHmxgCoFDU2/TEslIBX/HJnS7FWPcdYBGAb/ IJHg== X-Gm-Message-State: AOAM5335yOzysbnLF7S+bZ8GOw9SoSGyxQ1jYrHS+xCmQdMj7wUet/TD GZLUaW68iJu1sFewrKS0wfkU/Dy6NoP6Kr1MfvBr3koeP4vcg/AuDMFlHPuMADLzFThUQNrk/8F 3yueZ160tVkiFxFOmue0Phftk X-Received: by 2002:aa7:d40f:: with SMTP id z15mr289359edq.276.1611522795544; Sun, 24 Jan 2021 13:13:15 -0800 (PST) X-Received: by 2002:aa7:d40f:: with SMTP id z15mr289349edq.276.1611522795418; Sun, 24 Jan 2021 13:13:15 -0800 (PST) Received: from x1.localdomain (2001-1c00-0c1e-bf00-37a3-353b-be90-1238.cable.dynamic.v6.ziggo.nl. [2001:1c00:c1e:bf00:37a3:353b:be90:1238]) by smtp.gmail.com with ESMTPSA id g2sm7379705ejk.108.2021.01.24.13.13.14 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 24 Jan 2021 13:13:14 -0800 (PST) Subject: Re: [PATCH v4 11/13] ASoC: arizona-jack: Cleanup logging To: Andy Shevchenko Cc: Lee Jones , Cezary Rojewski , Pierre-Louis Bossart , Liam Girdwood , Jie Yang , Mark Brown , patches@opensource.cirrus.com, Linux Kernel Mailing List , Charles Keepax , ALSA Development Mailing List References: <20210123121313.79530-1-hdegoede@redhat.com> <20210123121720.79863-1-hdegoede@redhat.com> <20210123121720.79863-2-hdegoede@redhat.com> From: Hans de Goede Message-ID: <5aefbd9b-6e98-6cd7-bb98-80df88109a40@redhat.com> Date: Sun, 24 Jan 2021 22:13:13 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 1/24/21 8:53 PM, Andy Shevchenko wrote: > On Sat, Jan 23, 2021 at 2:17 PM Hans de Goede wrote: >> >> Cleanup the use of dev_foo functions used for logging: >> >> 1. Many of these are unnecessarily split over multiple lines >> 2. Use dev_err_probe() in cases where we might get a -EPROBE_DEFER >> return value > > ... > >> if (IS_ERR(info->micd_pol_gpio)) { >> ret = PTR_ERR(info->micd_pol_gpio); >> - dev_err(arizona->dev, >> - "Failed to get microphone polarity GPIO: %d\n", >> - ret); >> + dev_err_probe(arizona->dev, ret, "getting microphone polarity GPIO\n"); >> return ret; >> } > > I still think that using dev_err_probe() naturally, i.e. as a part of > the return statement is better. Just because it can be used that way does not mean that it must be used that way. More importantly I don't think that this small tihng is worth doing a v5 of this large series for. But if a v5 is necessary for other reasons, then I'll change this into: return dev_err_probe(arizona->dev, ret, "getting microphone polarity GPIO\n"); Regards, Hans