From patchwork Mon Jun 11 13:00:25 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sylwester Nawrocki X-Patchwork-Id: 9191 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id A9DA623E4F for ; Mon, 11 Jun 2012 13:00:30 +0000 (UTC) Received: from mail-gh0-f180.google.com (mail-gh0-f180.google.com [209.85.160.180]) by fiordland.canonical.com (Postfix) with ESMTP id 593ECA183AB for ; Mon, 11 Jun 2012 13:00:30 +0000 (UTC) Received: by ghbz12 with SMTP id z12so2647044ghb.11 for ; Mon, 11 Jun 2012 06:00:29 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf :dkim-signature:message-id:date:from:user-agent:mime-version:to:cc :subject:references:in-reply-to:content-type :content-transfer-encoding:x-gm-message-state; bh=tyBNFCV8JxyJX0sALD5+iD/gJmggF0d99cdE036INDo=; b=LlvGxJmwCVJVQGtMcOj6SkNv7I4X3FEdDjmk7EQFJDGcfOwLpyxnHwVJLDguc3fCvv Rksiel44Wwqg1yaz3dusilMmUUIuH8V6x2Ry1895gktm12nSOesjXaTbKb6CDO74fsa7 Z1sRk7zchH1KqVO5zqkKDRHHH1alr7HSLZI/EY45FYzqgZ1blC/mqcZUZlOyTbrjMsD8 QaSuh4jMToItdIm8AxyNY7lAcKsE9DZ528aPVqCQG8MXjvI0aD5r2ILXmP2rXkJMN7v/ mD+UWzEdFFsGRfOs0bIPsK12PCAFHWyREvNjUTH1wMeTLkwNG8scdqkUE+gi1BqIzFhw s3SA== Received: by 10.50.87.227 with SMTP id bb3mr6017373igb.57.1339419629662; Mon, 11 Jun 2012 06:00:29 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.231.24.148 with SMTP id v20csp107844ibb; Mon, 11 Jun 2012 06:00:28 -0700 (PDT) Received: by 10.204.151.82 with SMTP id b18mr10107667bkw.132.1339419628006; Mon, 11 Jun 2012 06:00:28 -0700 (PDT) Received: from mail-bk0-f50.google.com (mail-bk0-f50.google.com [209.85.214.50]) by mx.google.com with ESMTPS id hs17si10040548bkc.85.2012.06.11.06.00.27 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 11 Jun 2012 06:00:27 -0700 (PDT) Received-SPF: pass (google.com: domain of snjw23@gmail.com designates 209.85.214.50 as permitted sender) client-ip=209.85.214.50; Authentication-Results: mx.google.com; spf=pass (google.com: domain of snjw23@gmail.com designates 209.85.214.50 as permitted sender) smtp.mail=snjw23@gmail.com; dkim=pass header.i=@gmail.com Received: by bkcjg9 with SMTP id jg9so5222342bkc.37 for ; Mon, 11 Jun 2012 06:00:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=tyBNFCV8JxyJX0sALD5+iD/gJmggF0d99cdE036INDo=; b=O0x363tJXOrmRvTRMniee86CZ2HNgnXLiAPUCJgRddCeKQVz/xESfnbRJwXkWOTrWh UJMbEYALXkna4Slv0qwVJDvFoVTa2DagkhmNX4T6AVTsYRQz37jHvlHLCfnqJAn6h3K8 AVhV29Mf6WqbiR6d0RC5zwRjXptH7Sb+PZqU+LUpdBMgp4OjrExWRmhyrDi8zwtdUgvC XxC8JYqH5lKmmyXgPAuC/W0b8BfiP7P4b/lf5bS2HShw0qUgEidw65wOcD+4ZS8yYE1L zTX8L1jlb27rrQYFJyR+gqX+3o2RnbYnyr+EGL9491TqC2Abar+JPxAu78lzAG8Rdz9j lO5g== Received: by 10.204.152.13 with SMTP id e13mr10535216bkw.46.1339419626905; Mon, 11 Jun 2012 06:00:26 -0700 (PDT) Received: from [192.168.1.110] (031011252076.warszawa.vectranet.pl. [31.11.252.76]) by mx.google.com with ESMTPS id n17sm16300096bkw.5.2012.06.11.06.00.25 (version=SSLv3 cipher=OTHER); Mon, 11 Jun 2012 06:00:26 -0700 (PDT) Message-ID: <4FD5EBE9.509@gmail.com> Date: Mon, 11 Jun 2012 15:00:25 +0200 From: Sylwester Nawrocki User-Agent: Mozilla/5.0 (X11; Linux i686; rv:12.0) Gecko/20120430 Thunderbird/12.0.1 MIME-Version: 1.0 To: Sachin Kamat CC: linux-media@vger.kernel.org, t.stanislaws@samsung.com, k.debski@samsung.com, s.nawrocki@samsung.com, kyungmin.park@samsung.com, mchehab@infradead.org, patches@linaro.org Subject: Re: [PATCH 3/3] [media] s5p-fimc: Replace printk with pr_* functions References: <1339409634-13657-1-git-send-email-sachin.kamat@linaro.org> <1339409634-13657-3-git-send-email-sachin.kamat@linaro.org> In-Reply-To: <1339409634-13657-3-git-send-email-sachin.kamat@linaro.org> X-Gm-Message-State: ALoCoQlK4ed4RZDMit3qhaVqgSuSxDNRtgyvKJw79Kk6qLT5QnM5LZudce0PUczACnUliGI+vSTF Hi Sachin, On 06/11/2012 12:13 PM, Sachin Kamat wrote: > Replace printk with pr_* functions to silence checkpatch warnings. > > Signed-off-by: Sachin Kamat > --- > drivers/media/video/s5p-fimc/fimc-core.h | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/drivers/media/video/s5p-fimc/fimc-core.h b/drivers/media/video/s5p-fimc/fimc-core.h > index 95b27ae..c22fb0a 100644 > --- a/drivers/media/video/s5p-fimc/fimc-core.h > +++ b/drivers/media/video/s5p-fimc/fimc-core.h > @@ -28,7 +28,7 @@ > #include > > #define err(fmt, args...) \ > - printk(KERN_ERR "%s:%d: " fmt "\n", __func__, __LINE__, ##args) > + pr_err("%s:%d: " fmt "\n", __func__, __LINE__, ##args) I don't think it's worth the effort. If you really want to get rid of that warnings, please remove the err() macro altogether and do something like this instead: 8<---------------------------------------------------------------- 8>---------------------------------------------------------------- Thanks! Sylwester diff --git a/drivers/media/video/s5p-fimc/fimc-core.h b/drivers/media/video/s5p-fimc/fimc-core.h index 95b27ae..808ccc6 100644 --- a/drivers/media/video/s5p-fimc/fimc-core.h +++ b/drivers/media/video/s5p-fimc/fimc-core.h @@ -27,9 +27,6 @@ #include #include -#define err(fmt, args...) \ - printk(KERN_ERR "%s:%d: " fmt "\n", __func__, __LINE__, ##args) - #define dbg(fmt, args...) \ pr_debug("%s:%d: " fmt "\n", __func__, __LINE__, ##args) diff --git a/drivers/media/video/s5p-fimc/fimc-reg.c b/drivers/media/video/s5p-fimc/fimc-reg.c index 1fc4ce8..74a2fba 100644 --- a/drivers/media/video/s5p-fimc/fimc-reg.c +++ b/drivers/media/video/s5p-fimc/fimc-reg.c @@ -683,8 +683,8 @@ int fimc_hw_set_camera_type(struct fimc_dev *fimc, cfg |= FIMC_REG_CIGCTRL_CAM_JPEG; break; default: - v4l2_err(fimc->vid_cap.vfd, - "Not supported camera pixel format: %d", + v4l2_err(vid_cap->vfd, + "Not supported camera pixel format: %#x\n", vid_cap->mf.code); return -EINVAL; } @@ -699,7 +699,7 @@ int fimc_hw_set_camera_type(struct fimc_dev *fimc, } else if (cam->bus_type == FIMC_LCD_WB) { cfg |= FIMC_REG_CIGCTRL_CAMIF_SELWB; } else { - err("invalid camera bus type selected\n"); + v4l2_err(vid_cap->vfd, "Invalid camera bus type selected\n"); return -EINVAL; } writel(cfg, fimc->regs + FIMC_REG_CIGCTRL);