From: ebiederm@xmission.com (Eric W. Biederman)
To: "linux-os \(Dick Johnson\)" <linux-os@analogic.com>
Cc: "Kumar Gala" <galak@kernel.crashing.org>,
"Benjamin LaHaise" <bcrl@kvack.org>,
"Vivek Goyal" <vgoyal@in.ibm.com>,
"linux kernel mailing list" <linux-kernel@vger.kernel.org>,
"Fastboot mailing list" <fastboot@lists.osdl.org>,
"Morton Andrew Morton" <akpm@osdl.org>, <gregkh@suse.de>
Subject: Re: [RFC][PATCH] Expanding the size of "start" and "end" field in "struct resource"
Date: Wed, 15 Mar 2006 14:37:38 -0700 [thread overview]
Message-ID: <m1oe07e6e5.fsf@ebiederm.dsl.xmission.com> (raw)
In-Reply-To: <Pine.LNX.4.61.0603151617010.4346@chaos.analogic.com> (linux-os@analogic.com's message of "Wed, 15 Mar 2006 16:26:16 -0500")
"linux-os \(Dick Johnson\)" <linux-os@analogic.com> writes:
> ix86 machines need to make many operations just to increment
> or decrement a 64-bit variable, plus the operations are not
> atomic so they need to be protected. The bloat of using 64-bit
> objects in 32-bit machines is very real and a tremendous problem.
> That's why all the stuff in the kernel wasn't 'long long' to
> begin with. It's execution bloat, a.k.a., time expansion that
> is the problem.
>
> Bump a 32-bit variable, addressed from an index register:
>
> incl (%ebx)
>
> Bump a 64-bit variable, addressed the same way.
>
> addl $1,(%ebx) ; Need to add because inc doesn't carry
> adcl $0,4(%ebx) ; Add 0 plus the carry-flag
>
> If an interrupt or context-switch comes between the two operations,
> the result is undefined, NotGood(tm).
No it is well defined it just isn't atomic. But difference.
The thing is struct resource is accessed less often the file
offsets which are already 64bit. Basically they are only
used during driver initialization.
So while I agree in general that 64bit values should be avoided
this is one of those places where we can productively use a
64bit value, on a 32bit machine.
To keep using 32bit kernels on the newer x86 machines at some
point this will even become a requirement as 64bit BAR will
actually have 64bit values placed in them.
Eric
next prev parent reply other threads:[~2006-03-15 21:39 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-15 19:31 Vivek Goyal
2006-03-15 19:48 ` Kumar Gala
2006-03-15 19:57 ` Arjan van de Ven
2006-03-15 20:01 ` Kumar Gala
2006-03-15 20:10 ` Kumar Gala
2006-03-15 20:13 ` Eric W. Biederman
2006-03-15 20:28 ` Kumar Gala
2006-03-15 20:37 ` Eric W. Biederman
2006-03-15 20:32 ` Vivek Goyal
2006-03-15 20:58 ` Eric W. Biederman
2006-03-15 21:57 ` David S. Miller
2006-03-15 20:53 ` Benjamin LaHaise
2006-03-15 21:05 ` Kumar Gala
2006-03-15 21:13 ` Benjamin LaHaise
2006-03-15 21:29 ` Eric W. Biederman
2006-03-15 21:28 ` Benjamin LaHaise
2006-03-15 21:50 ` Eric W. Biederman
2006-03-15 22:13 ` Andrew Morton
2006-03-15 22:18 ` David S. Miller
2006-03-15 21:59 ` Eric W. Biederman
2006-03-15 22:07 ` Benjamin LaHaise
2006-03-16 14:45 ` Eric W. Biederman
2006-03-15 21:30 ` Kumar Gala
2006-03-15 21:35 ` hackmiester / Hunter Fuller
2006-03-15 21:31 ` Eric W. Biederman
2006-03-15 21:15 ` Eric W. Biederman
2006-03-15 21:26 ` linux-os (Dick Johnson)
2006-03-15 21:37 ` Eric W. Biederman [this message]
2006-03-15 22:08 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m1oe07e6e5.fsf@ebiederm.dsl.xmission.com \
--to=ebiederm@xmission.com \
--cc=akpm@osdl.org \
--cc=bcrl@kvack.org \
--cc=fastboot@lists.osdl.org \
--cc=galak@kernel.crashing.org \
--cc=gregkh@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-os@analogic.com \
--cc=vgoyal@in.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®