From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753235AbaIOO3u (ORCPT ); Mon, 15 Sep 2014 10:29:50 -0400 Received: from cantor2.suse.de ([195.135.220.15]:39850 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752579AbaIOO3t (ORCPT ); Mon, 15 Sep 2014 10:29:49 -0400 Date: Mon, 15 Sep 2014 16:29:48 +0200 Message-ID: From: Takashi Iwai To: Sudip Mukherjee Cc: Jaroslav Kysela , alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] sound: pci: ctxfi: pr_* replaced with dev_* In-Reply-To: <1410790181-16457-1-git-send-email-sudipm.mukherjee@gmail.com> References: <1410790181-16457-1-git-send-email-sudipm.mukherjee@gmail.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/24.3 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org At Mon, 15 Sep 2014 19:39:41 +0530, Sudip Mukherjee wrote: > > pr_* macros replaced with dev_* as they are more preffered over pr_*. > > Signed-off-by: Sudip Mukherjee > --- > > in v1 Takashi mentioned that now we have card->dev > so v2 is using card->dev as much as possible. > > sound/pci/ctxfi/ctatc.c | 24 ++++++++++++++---------- > sound/pci/ctxfi/cthw20k1.c | 15 +++++++++------ > sound/pci/ctxfi/cthw20k2.c | 22 ++++++++++++++-------- > sound/pci/ctxfi/ctmixer.c | 6 ++++-- > sound/pci/ctxfi/ctpcm.c | 9 ++++++--- > sound/pci/ctxfi/ctresource.c | 20 +++++++++++++------- > sound/pci/ctxfi/xfi.c | 15 +++++++++------ > 7 files changed, 69 insertions(+), 42 deletions(-) > > diff --git a/sound/pci/ctxfi/ctatc.c b/sound/pci/ctxfi/ctatc.c > index d92a08c..a786bc1 100644 > --- a/sound/pci/ctxfi/ctatc.c > +++ b/sound/pci/ctxfi/ctatc.c > @@ -1282,8 +1282,8 @@ static int atc_identify_card(struct ct_atc *atc, unsigned int ssid) > p = snd_pci_quirk_lookup_id(vendor_id, device_id, list); > if (p) { > if (p->value < 0) { > - pr_err("ctxfi: Device %04x:%04x is black-listed\n", > - vendor_id, device_id); > + dev_err(atc->card->dev, "ctxfi: Device %04x:%04x is black-listed\n", > + vendor_id, device_id); You need no prefix for dev_xxx(). > diff --git a/sound/pci/ctxfi/ctresource.c b/sound/pci/ctxfi/ctresource.c > index e49d2be..80beecb 100644 > --- a/sound/pci/ctxfi/ctresource.c > +++ b/sound/pci/ctxfi/ctresource.c (snip) > @@ -282,8 +287,9 @@ int rsc_mgr_uninit(struct rsc_mgr *mgr) > case SUM: > break; > default: > - pr_err("ctxfi: Invalid resource type value %d!\n", > - mgr->type); > + dev_err(&(((struct hw *)mgr->hw)->pci->dev), > + "ctxfi: Invalid resource type value %d!\n", > + mgr->type); Did you really conclude that this is the best way? Also, is it good to mix up the usages of both card->dev and &pci->dev? Think again. thanks, Takashi