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: <47E9C56F.2070508@pobox.com>
Date:	Tue, 25 Mar 2008 23:39:27 -0400
From:	Jeff Garzik <jgarzik@...ox.com>
To:	David Miller <davem@...emloft.net>
CC:	yang.shi@...driver.com, netdev@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Improvev netconsole support for RTL8139 NIC driver

David Miller wrote:
> From: Jeff Garzik <jgarzik@...ox.com>
> Date: Tue, 25 Mar 2008 23:14:03 -0400
> 
>> David Miller wrote:
>>> From: Jeff Garzik <jgarzik@...ox.com>
>>> Date: Tue, 25 Mar 2008 22:23:24 -0400
>>>
>>>> This is bogus -- you should never need to slow down the hot path in such 
>>>> a way.
>>> Slow down in what way?  Even on x86 saving the flags is just
>>> about as expensive as a plain sti/cli.
>> Replacing spin_lock() [current 8139too.c] with spin_lock_irqsave() 
>> results in a larger interrupt handler... more CPU instructions for the 
>> same result.
> 
> Jeff, please be realistic.
> 
> These interrupt handlers about to do a PIO on a status register, which
> will consume on the order of a few hundred cpu cycles.
> 
> Counting an I-cache line or two, or 18 cycles here or there,
> is immaterial by comparison.

I am being realistic...  it's

* not needed
* increases code size
* increases number of CPU instructions executed
* not needed

Thus applying this consistency rule across N drivers needlessly 
increases the code size of N drivers.

Mainly I see such a change as a violation of a basic Linux principle: 
do what you must, and no more.

	Jeff



--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ