From patchwork Tue Nov 12 06:51:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?Q2h1bmZlbmcgWXVuICjkupHmmKXls7Ap?= X-Patchwork-Id: 11238639 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 71FA813B1 for ; Tue, 12 Nov 2019 06:52:10 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 51EA621783 for ; Tue, 12 Nov 2019 06:52:10 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b="HKcMpgHZ" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727080AbfKLGwJ (ORCPT ); Tue, 12 Nov 2019 01:52:09 -0500 Received: from mailgw01.mediatek.com ([210.61.82.183]:3766 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1725283AbfKLGwJ (ORCPT ); Tue, 12 Nov 2019 01:52:09 -0500 X-UUID: 225456d538b04c4998060d30a6ac8cf6-20191112 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID:Date:Subject:CC:To:From; bh=d8BFCFk1jWo76KszBymxQCa+dx51d98IKSWXcuFIpgA=; b=HKcMpgHZ0Ij+spH0BoNSPXCa0NI/iEymiLXFw+LVn8Vcz/nHXie7RV7j15gGvl7mEOJnT78eq7l8yitBVAccSw0V1BzKWeZV1CxgBF4buzRUvqy2IIDg2KttPLo/FKclmaeRPvJFKlfhRzfbMIVMxrHKQNILtL65yy7rCg/9Q80=; X-UUID: 225456d538b04c4998060d30a6ac8cf6-20191112 Received: from mtkcas06.mediatek.inc [(172.21.101.30)] by mailgw01.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 1160445928; Tue, 12 Nov 2019 14:52:04 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by mtkmbs08n1.mediatek.inc (172.21.101.55) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Tue, 12 Nov 2019 14:52:02 +0800 Received: from localhost.localdomain (10.17.3.153) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Tue, 12 Nov 2019 14:52:00 +0800 From: Chunfeng Yun To: Greg Kroah-Hartman , Felipe Balbi CC: Laurent Pinchart , Mauro Carvalho Chehab , Peter Chen , Minas Harutyunyan , Cristian Birsan , Nicolas Ferre , Alexandre Belloni , Ludovic Desroches , Kevin Cernekee , Florian Fainelli , , Daniel Mack , Haojian Zhuang , Robert Jarzmik , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Bin Liu , Matthias Brugger , Stephen Boyd , Chunfeng Yun , Yoshihiro Shimoda , Colin Ian King , Biju Das , Fabrizio Castro , "Gustavo A. R. Silva" , Yangtao Li , , , , , Subject: [PATCH v2 01/13] media: uvcvideo: drop error check of debugfs_create_dir() Date: Tue, 12 Nov 2019 14:51:47 +0800 Message-ID: <1573541519-28488-1-git-send-email-chunfeng.yun@mediatek.com> X-Mailer: git-send-email 1.8.1.1.dirty MIME-Version: 1.0 X-MTK: N Sender: linux-usb-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org No need check the return value of debugfs_create_dir() Signed-off-by: Chunfeng Yun --- v2: 1. abandon new API usb_debugfs_create_dir(), and drop error check --- drivers/media/usb/uvc/uvc_debugfs.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/drivers/media/usb/uvc/uvc_debugfs.c b/drivers/media/usb/uvc/uvc_debugfs.c index d2b109959d82..2b8af4b54117 100644 --- a/drivers/media/usb/uvc/uvc_debugfs.c +++ b/drivers/media/usb/uvc/uvc_debugfs.c @@ -108,15 +108,7 @@ void uvc_debugfs_cleanup_stream(struct uvc_streaming *stream) void uvc_debugfs_init(void) { - struct dentry *dir; - - dir = debugfs_create_dir("uvcvideo", usb_debug_root); - if (IS_ERR_OR_NULL(dir)) { - uvc_printk(KERN_INFO, "Unable to create debugfs directory\n"); - return; - } - - uvc_debugfs_root_dir = dir; + uvc_debugfs_root_dir = debugfs_create_dir("uvcvideo", usb_debug_root); } void uvc_debugfs_cleanup(void)