mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Yadan Fan <ydfan@suse.com>
To: sfrench@samba.org, linux-cifs@vger.kernel.org
Cc: samba-technical@lists.samba.org, linux-kernel@vger.kernel.org,
	martin.schwidefsky@de.ibm.com, Yadan Fan <ydfan@suse.com>
Subject: [PATCH] s390x: fix condition to choose correct function
Date: Wed, 24 Feb 2016 14:45:47 +0800	[thread overview]
Message-ID: <1456296347-9665-1-git-send-email-ydfan@suse.com> (raw)

This issue is involved from commit 02323db17e3a7 ("cifs: fix
cifs_uniqueid_to_ino_t not to ever return 0"), when BITS_PER_LONG
is 64 on s390x, the corresponding cifs_uniqueid_to_ino_t()
function will cast 64-bit fileid to 32-bit by using (ino_t)fileid,
because ino_t (typdefed __kernel_ino_t) is int type.

Signed-off-by: Yadan Fan <ydfan@suse.com>
---
 fs/cifs/cifsfs.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/cifs/cifsfs.h b/fs/cifs/cifsfs.h
index 68c4547..02dcbe1 100644
--- a/fs/cifs/cifsfs.h
+++ b/fs/cifs/cifsfs.h
@@ -31,7 +31,7 @@
  * so that it will fit. We use hash_64 to convert the value to 31 bits, and
  * then add 1, to ensure that we don't end up with a 0 as the value.
  */
-#if BITS_PER_LONG == 64
+#if BITS_PER_LONG == 64 && !defined(CONFIG_S390)
 static inline ino_t
 cifs_uniqueid_to_ino_t(u64 fileid)
 {
-- 
2.6.2

             reply	other threads:[~2016-02-24  6:47 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-24  6:45 Yadan Fan [this message]
2016-02-29  4:17 ` Steve French

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=1456296347-9665-1-git-send-email-ydfan@suse.com \
    --to=ydfan@suse.com \
    --cc=linux-cifs@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=martin.schwidefsky@de.ibm.com \
    --cc=samba-technical@lists.samba.org \
    --cc=sfrench@samba.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®