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=-9.8 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT 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 73024C433DF for ; Tue, 23 Jun 2020 15:07:54 +0000 (UTC) Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (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 4350D2073E for ; Tue, 23 Jun 2020 15:07:54 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=microchip.com header.i=@microchip.com header.b="g0JJiu2k" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4350D2073E Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=microchip.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=driverdev-devel-bounces@linuxdriverproject.org Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 2E61A88E62; Tue, 23 Jun 2020 15:07:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Xkt6S6-ky6SR; Tue, 23 Jun 2020 15:07:51 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id B47D788E85; Tue, 23 Jun 2020 15:07:48 +0000 (UTC) Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 1435C1BF3ED for ; Tue, 23 Jun 2020 15:07:48 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 042DF88EC2 for ; Tue, 23 Jun 2020 15:07:48 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id VPSiR3HQm66c for ; Tue, 23 Jun 2020 15:07:45 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from esa6.microchip.iphmx.com (esa6.microchip.iphmx.com [216.71.154.253]) by whitealder.osuosl.org (Postfix) with ESMTPS id E81AA88E4E for ; Tue, 23 Jun 2020 15:07:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1592924863; x=1624460863; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version; bh=vJNxpQRr0TuLJ5CXtzdM9nP9esA5w30En4pitGx4lAs=; b=g0JJiu2kvHE2HISU50FMvTI4cqXWRdHCyqIAlArBuzH2+GAip1++nMmf WX9F7Zxl9IPVOXICCHU0iW9CEJg9UWLGJ6HeFdJ+wTNduUvrJMKZf8s5v Mo8Rd4sJNBi/kZMQiUZpbr2kzVR8vwF859yCTG99IKLtkaW2qKLmrkonB 6i/rMGIKStu5NZZXUxRKpBfP4iOwWfrD9Owfa8GV3lA9sV8yb1V+IZDBf oBbop1EbCzs2NgjSkiJf+fZr7Q7JIhjUWQpmqJL1G3vqmQMoSd5/NmJgU JlHfBpgwSdaZG4yFwTL9VXsJZhG59iGPspMevXJ64wiNJoWIWLaCpPveD g==; IronPort-SDR: GMV7GHkBi262t+0s8cuVw6Gu+EF/tTPNg9QUkrEm5SdfO7i59VMCDZGbRbJiBQR4yR/gyEbeNw 3eQpn1AncMX2VYFmj4x4nJlE/+hJPgLt4UkxGTOjibJoe7/ucUjGYg/dbxs0t9oZDfavZ4/KPw YjrsyLCb0KRvPMyzMafpICbp/1Q3ZJTCrhvW+V7FzW8O/mW1HWHuHo7c6ClFrLgWDW8LpL+RvH fAJcW1jHPv910HLHffkx+1g/eMVKmcGABTGxGNWddMUYseXHEbFlEQyJEvOSCn3Qdq75Po8AZI 4sI= X-IronPort-AV: E=Sophos;i="5.75,271,1589266800"; d="scan'208";a="16763298" Received: from smtpout.microchip.com (HELO email.microchip.com) ([198.175.253.82]) by esa6.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 23 Jun 2020 08:07:43 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1979.3; Tue, 23 Jun 2020 08:07:32 -0700 Received: from kar-sv-agl01.mchp-main.com (10.10.115.15) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server id 15.1.1979.3 via Frontend Transport; Tue, 23 Jun 2020 08:07:42 -0700 From: Christian Gromm To: Subject: [PATCH 5/5] staging: most: sound: remove overcautious argument checking Date: Tue, 23 Jun 2020 17:07:35 +0200 Message-ID: <1592924855-25569-6-git-send-email-christian.gromm@microchip.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1592924855-25569-1-git-send-email-christian.gromm@microchip.com> References: <1592924855-25569-1-git-send-email-christian.gromm@microchip.com> MIME-Version: 1.0 X-BeenThere: driverdev-devel@linuxdriverproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Driver Project Developer List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Christian Gromm , driverdev-devel@linuxdriverproject.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: driverdev-devel-bounces@linuxdriverproject.org Sender: "devel" The interface pointer passed to a component API function cannot be NULL. This patch removes the unnecessary sanity check of this argument. Signed-off-by: Christian Gromm --- drivers/staging/most/sound/sound.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/staging/most/sound/sound.c b/drivers/staging/most/sound/sound.c index 7c56cdb..8a449ab 100644 --- a/drivers/staging/most/sound/sound.c +++ b/drivers/staging/most/sound/sound.c @@ -531,9 +531,6 @@ static int audio_probe_channel(struct most_interface *iface, int channel_id, char *sample_res; char arg_list_cpy[STRING_SIZE]; - if (!iface) - return -EINVAL; - if (cfg->data_type != MOST_CH_SYNC) { pr_err("Incompatible channel type\n"); return -EINVAL; -- 2.7.4 _______________________________________________ devel mailing list devel@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel