From nobody Thu Apr 21 17:30:15 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 0E9D71991431; Thu, 21 Apr 2022 17:30:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Kkl132wp9z4Wmd; Thu, 21 Apr 2022 17:30:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1650562215; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pKodpF3lFUxfuT6MSWaOdAtP/7c3outocDpxVUtQYxg=; b=RR0+4Axl5OwURNcGU5sNq2dbyzTQRcUBs8dYb+Afue+05gy7egFr+KKCN/xAy7E9PYM6re KMLaO2de81wXA6NoOs4fiy8qxl0t1nhqPhr+Twf2CILyZv6kg7RJMzuKnXfSAupzBzBChx VtxwB9OuoBPohInuqNFWeEwdRH/GBnA/QaQbcd9QRYpYWTg+t+HlHlGyvhX/AtSFGLNRtI jUIJdWEiDhGx4u6XRqHKD8DdL952pL1SkOILX+makG+IQr5twKxT8U+irnFDm2sf/Le+Jc FlsLMHMLD5a/iscf+wQmijZXV3xB/ZVikt9NilKiZlRRX1T0ukoyp5OZTHilOA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 32F1650F8; Thu, 21 Apr 2022 17:30:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 23LHUF8d005155; Thu, 21 Apr 2022 17:30:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 23LHUFj0005149; Thu, 21 Apr 2022 17:30:15 GMT (envelope-from git) Date: Thu, 21 Apr 2022 17:30:15 GMT Message-Id: <202204211730.23LHUFj0005149@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 108adb2ff52c - main - arcmsr: Remove never-true NULL check from cdev callbacks. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 108adb2ff52c73a92837452ef3ed641053bd1b6f Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1650562215; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pKodpF3lFUxfuT6MSWaOdAtP/7c3outocDpxVUtQYxg=; b=Ww1rARxYN30lmcl9oaci0arRi28tUL5vzA1RLkpLHd5XxIylS9W2uFzhGoY3VTGJPCjtr3 ur1hW0j4xD3kS62IZIykiyaY497TYHCmJw7cC9qD76x8NxkCrfGnT4IVt7YnyOP8YCC/lR R7dYijIs7TnqkZ6hNPidKJ9WIciCPqbtnJ4t8yGqKXNjOrkL/1Yjbdsc9FEydGfxkSZebW /bh2r9aKHK1JBKYL09QFtiqinshJMmK0tExLTsQNGQRidGRxrrSbQOb6v6gvd0Ck4qrnO9 1PApZHyxJOz2xDGHP7IcZyoSx1deeMx5owe3b2tsKz+4+jhDwh4sXeRW7INFTg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1650562215; a=rsa-sha256; cv=none; b=QwHyuRWKxBCiQ/v3wXFNs8llMflkD2h5HGjWPcX8ibNEQUnZpIc69qPcGkAX6TY40QEmln FvlykFG2o1PrfHLzESVvylUaUwEz8OP1+qShAlWSyJsrzHpTRcZlDjgs6y+rNPsvWV/cD7 pE72FIulcI1k3petfp4pI3klup4SVYpj9E/OFV5/2jgnYm3GLHqBF2xlDRu4zJGCX4fpbr 62KVJsYCZeOGT9NXr18geYURMTQL3vaTirqngSFYYW7wrZDWNwSLMwm2BmFTaXPG4LcOkB qmP5fkLdDfxcaBf2cMwfXZhP0afHjrFDyvEdPpgaxA0tteY6BxAfLpei/lRUhw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=108adb2ff52c73a92837452ef3ed641053bd1b6f commit 108adb2ff52c73a92837452ef3ed641053bd1b6f Author: John Baldwin AuthorDate: 2022-04-21 17:29:14 +0000 Commit: John Baldwin CommitDate: 2022-04-21 17:29:14 +0000 arcmsr: Remove never-true NULL check from cdev callbacks. si_drv1 will always hold a non-NULL pointer. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D35005 --- sys/dev/arcmsr/arcmsr.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/sys/dev/arcmsr/arcmsr.c b/sys/dev/arcmsr/arcmsr.c index 87147402d091..2a1b0250364f 100644 --- a/sys/dev/arcmsr/arcmsr.c +++ b/sys/dev/arcmsr/arcmsr.c @@ -240,11 +240,6 @@ static struct cdevsw arcmsr_cdevsw={ */ static int arcmsr_open(struct cdev *dev, int flags, int fmt, struct thread *proc) { - struct AdapterControlBlock *acb = dev->si_drv1; - - if (acb == NULL) { - return ENXIO; - } return (0); } /* @@ -253,11 +248,6 @@ static int arcmsr_open(struct cdev *dev, int flags, int fmt, struct thread *proc */ static int arcmsr_close(struct cdev *dev, int flags, int fmt, struct thread *proc) { - struct AdapterControlBlock *acb = dev->si_drv1; - - if (acb == NULL) { - return ENXIO; - } return 0; } /* @@ -268,9 +258,6 @@ static int arcmsr_ioctl(struct cdev *dev, u_long ioctl_cmd, caddr_t arg, int fla { struct AdapterControlBlock *acb = dev->si_drv1; - if (acb == NULL) { - return ENXIO; - } return (arcmsr_iop_ioctlcmd(acb, ioctl_cmd, arg)); } /*