lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <81a72082-94ec-4011-1e54-3b278317a44e@deltatee.com>
Date:   Thu, 15 Dec 2022 11:34:06 -0700
From:   Logan Gunthorpe <logang@...tatee.com>
To:     Bjorn Helgaas <helgaas@...nel.org>,
        Kurt Schwemmer <kurt.schwemmer@...rosemi.com>
Cc:     linux-pci@...r.kernel.org, linux-kernel@...r.kernel.org,
        Bjorn Helgaas <bhelgaas@...gle.com>
Subject: Re: [PATCH 2/2] PCI: switchtec: Remove useless assignments in
 switchtec_dev_read()



On 2022-12-15 11:21, Bjorn Helgaas wrote:
> From: Bjorn Helgaas <bhelgaas@...gle.com>
> 
> Some switchtec_dev_read() error cases assign to "rc", then branch to "out".
> But the code at "out" never uses "rc".  Drop the useless assignments.  No
> functional change intended.

Ah, hmm, yes. I think if copy_to_user() fails, the function should
probably return -EFAULT. So perhaps an unlock and specific return as is
done in previous conditions in the same function?

Thanks,

Logan

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ