From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6C776C43381 for ; Fri, 8 Mar 2019 02:33:49 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 45A942146E for ; Fri, 8 Mar 2019 02:33:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726412AbfCHCdr (ORCPT ); Thu, 7 Mar 2019 21:33:47 -0500 Received: from smtprelay0098.hostedemail.com ([216.40.44.98]:57676 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726275AbfCHCdr (ORCPT ); Thu, 7 Mar 2019 21:33:47 -0500 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay07.hostedemail.com (Postfix) with ESMTP id AEB07181D3403; Fri, 8 Mar 2019 02:33:45 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-HE-Tag: voice01_3d2bd574b284c X-Filterd-Recvd-Size: 2623 Received: from XPS-9350 (unknown [149.142.244.224]) (Authenticated sender: joe@perches.com) by omf15.hostedemail.com (Postfix) with ESMTPA; Fri, 8 Mar 2019 02:33:39 +0000 (UTC) Message-ID: <58d834c0b0aeeb7e551e101a696ab8faf9d41b61.camel@perches.com> Subject: Re: [PATCH v2 2/6] staging: video: rockchip: add v4l2 decoder From: Joe Perches To: Randy Li , linux-media@vger.kernel.org Cc: Randy Li , hverkuil@xs4all.nl, maxime.ripard@bootlin.com, joro@8bytes.org, linux-kernel@vger.kernel.org, jernej.skrabec@gmail.com, nicolas@ndufresne.ca, paul.kocialkowski@bootlin.com, linux-rockchip@lists.infradead.org, thomas.petazzoni@bootlin.com, mchehab@kernel.org, ezequiel@collabora.com, linux-arm-kernel@lists.infradead.org, posciak@chromium.org, groeck@chromium.org Date: Thu, 07 Mar 2019 18:33:37 -0800 In-Reply-To: <20190307100316.925-3-randy.li@rock-chips.com> References: <20190307100316.925-1-randy.li@rock-chips.com> <20190307100316.925-3-randy.li@rock-chips.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.30.1-1build1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2019-03-07 at 18:03 +0800, Randy Li wrote: > It is based on the vendor driver sent to mail list before. trivial notes: > diff --git a/drivers/staging/rockchip-mpp/mpp_debug.h b/drivers/staging/rockchip-mpp/mpp_debug.h [] > +#define mpp_debug_func(type, fmt, args...) \ > + do { \ > + if (unlikely(debug & type)) { \ > + pr_info("%s:%d: " fmt, \ > + __func__, __LINE__, ##args); \ > + } \ > + } while (0) > +#define mpp_debug(type, fmt, args...) \ > + do { \ > + if (unlikely(debug & type)) { \ > + pr_info(fmt, ##args); \ > + } \ > + } while (0) > + It's generally better to emit debug messages at KERN_DEBUG > +#define mpp_debug_enter() \ > + do { \ > + if (unlikely(debug & DEBUG_FUNCTION)) { \ > + pr_info("%s:%d: enter\n", \ > + __func__, __LINE__); \ > + } \ > + } while (0) > + > +#define mpp_debug_leave() \ > + do { \ > + if (unlikely(debug & DEBUG_FUNCTION)) { \ > + pr_info("%s:%d: leave\n", \ > + __func__, __LINE__); \ > + } \ > + } while (0) I suggest removal of these macros and uses. There's not much value in enter/leave markings as the generic ftrace facility does this already. > + > +#define mpp_err(fmt, args...) \ > + pr_err("%s:%d: " fmt, __func__, __LINE__, ##args) __func__, __LINE__ markings generally have little value. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 890B6C10F03 for ; Fri, 8 Mar 2019 02:34:13 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 5BF742081B for ; Fri, 8 Mar 2019 02:34:13 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="uCQmKtHz" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 5BF742081B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=perches.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Mime-Version:References:In-Reply-To: Date:To:From:Subject:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=I5JEY92qaJtiXfyka0Rp+ZAzyyYQvQh5QeVWO2kFn7A=; b=uCQmKtHzz439ly QDsSL5gfj3S9snR+E6xt7GM5j3tfY0oZnlpn335S2b3nnyev/09ijvpP8Czes7qZ7MUj4QkCx10y6 WmPRuI2H3edc4Dj4bIXzV53XUdnuoUU72Evab7jQ2Fm9fWHODDpHbt5W5mqH3jMzmQOM81w5uUtN9 SA4TMrImvtM2SR3ZSVns59EW9zl5M1zruZ3jYYQFftRRXNP8WUWiKV9CiZ/l86gq+sO77Y7b6kXKm kzi8XP3GtEa7g/N1HPNMzkwJsz0PS15q5EYFqIn2rPgc+F4i9V4VBFtLvR3GB7h0TGWbCqXPq2eOm 4F5Od4Sg/UwuTsdsR6tw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1h25Kj-0001SE-Rj; Fri, 08 Mar 2019 02:34:01 +0000 Received: from smtprelay0133.hostedemail.com ([216.40.44.133] helo=smtprelay.hostedemail.com) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h25Kh-0001Rm-3k; Fri, 08 Mar 2019 02:34:00 +0000 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay07.hostedemail.com (Postfix) with ESMTP id AEB07181D3403; Fri, 8 Mar 2019 02:33:45 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-HE-Tag: voice01_3d2bd574b284c X-Filterd-Recvd-Size: 2623 Received: from XPS-9350 (unknown [149.142.244.224]) (Authenticated sender: joe@perches.com) by omf15.hostedemail.com (Postfix) with ESMTPA; Fri, 8 Mar 2019 02:33:39 +0000 (UTC) Message-ID: <58d834c0b0aeeb7e551e101a696ab8faf9d41b61.camel@perches.com> Subject: Re: [PATCH v2 2/6] staging: video: rockchip: add v4l2 decoder From: Joe Perches To: Randy Li , linux-media@vger.kernel.org Date: Thu, 07 Mar 2019 18:33:37 -0800 In-Reply-To: <20190307100316.925-3-randy.li@rock-chips.com> References: <20190307100316.925-1-randy.li@rock-chips.com> <20190307100316.925-3-randy.li@rock-chips.com> User-Agent: Evolution 3.30.1-1build1 Mime-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190307_183359_244951_AA2D8F22 X-CRM114-Status: UNSURE ( 7.78 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: paul.kocialkowski@bootlin.com, maxime.ripard@bootlin.com, joro@8bytes.org, Randy Li , linux-kernel@vger.kernel.org, jernej.skrabec@gmail.com, nicolas@ndufresne.ca, hverkuil@xs4all.nl, linux-rockchip@lists.infradead.org, posciak@chromium.org, thomas.petazzoni@bootlin.com, groeck@chromium.org, mchehab@kernel.org, ezequiel@collabora.com, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, 2019-03-07 at 18:03 +0800, Randy Li wrote: > It is based on the vendor driver sent to mail list before. trivial notes: > diff --git a/drivers/staging/rockchip-mpp/mpp_debug.h b/drivers/staging/rockchip-mpp/mpp_debug.h [] > +#define mpp_debug_func(type, fmt, args...) \ > + do { \ > + if (unlikely(debug & type)) { \ > + pr_info("%s:%d: " fmt, \ > + __func__, __LINE__, ##args); \ > + } \ > + } while (0) > +#define mpp_debug(type, fmt, args...) \ > + do { \ > + if (unlikely(debug & type)) { \ > + pr_info(fmt, ##args); \ > + } \ > + } while (0) > + It's generally better to emit debug messages at KERN_DEBUG > +#define mpp_debug_enter() \ > + do { \ > + if (unlikely(debug & DEBUG_FUNCTION)) { \ > + pr_info("%s:%d: enter\n", \ > + __func__, __LINE__); \ > + } \ > + } while (0) > + > +#define mpp_debug_leave() \ > + do { \ > + if (unlikely(debug & DEBUG_FUNCTION)) { \ > + pr_info("%s:%d: leave\n", \ > + __func__, __LINE__); \ > + } \ > + } while (0) I suggest removal of these macros and uses. There's not much value in enter/leave markings as the generic ftrace facility does this already. > + > +#define mpp_err(fmt, args...) \ > + pr_err("%s:%d: " fmt, __func__, __LINE__, ##args) __func__, __LINE__ markings generally have little value. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel