mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: randy.dunlap@oracle.com
Cc: andi@firstfloor.org, linux-kernel@vger.kernel.org,
	akpm@linux-foundation.org, sam@ravnborg.org
Subject: Re: [PATCH] make csum_partial obj-y
Date: Tue, 03 Apr 2007 12:27:08 -0700 (PDT)	[thread overview]
Message-ID: <20070403.122708.116354009.davem@davemloft.net> (raw)
In-Reply-To: <4612A66D.5090009@oracle.com>

From: Randy Dunlap <randy.dunlap@oracle.com>
Date: Tue, 03 Apr 2007 12:09:33 -0700

> How does the networking code work across multiple architectures?

This has been discussed before.

The csum_partial() result value is only well defined modulo 0xffff.

The networking does csum_fold() or similar on the results, and so the
right thing always happens there.

The reiserfs case is the worst because even ignoring the differences
in csum_partial() return values, it always feeds this into
cpu_to_le32() which basically means that it is putting a cpu-endian
dependent value onto disk.  csum_partial() returns a fixed-endian,
not cpu endian, value.  So feeding it into cpu_to_anything() is
quite wrong.



  parent reply	other threads:[~2007-04-03 19:27 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-03 18:26 Randy Dunlap
2007-04-03 20:02 ` Andi Kleen
2007-04-03 19:09   ` Randy Dunlap
2007-04-03 19:23     ` Andi Kleen
2007-04-03 19:27     ` David Miller [this message]
2007-04-03 19:31       ` Randy Dunlap

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=20070403.122708.116354009.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=akpm@linux-foundation.org \
    --cc=andi@firstfloor.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=randy.dunlap@oracle.com \
    --cc=sam@ravnborg.org \
    /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®