mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] NTFS sparc compile fix
@ 2001-11-03 20:36 Anton Altaparmakov
  2001-11-19  8:52 ` Albert D. Cahalan
  0 siblings, 1 reply; 2+ messages in thread
From: Anton Altaparmakov @ 2001-11-03 20:36 UTC (permalink / raw)
  To: torvalds, alan; +Cc: linux-kernel

Linus, Alan,

Please apply below patchlet for your next releases (applies cleanly to
any recent kernel). It fixes compilation of NTFS driver on Sparc.

Thanks to Jan-Benedict Glaw for reporting and testing.

Best regards,

	Anton
-- 
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Linux NTFS maintainer / WWW: http://linux-ntfs.sf.net/
ICQ: 8561279 / WWW: http://www-stu.christs.cam.ac.uk/~aia21/

--- ntfs-sparc.diff ---

diff -u -urN linux-2.4.14-pre7-vanilla/fs/ntfs/dir.c linux-2.4.14-pre7-ntfs/fs/ntfs/dir.c
--- linux-2.4.14-pre7-vanilla/fs/ntfs/dir.c	Wed Sep 12 01:02:46 2001
+++ linux-2.4.14-pre7-ntfs/fs/ntfs/dir.c	Sat Nov  3 17:56:40 2001
@@ -19,6 +19,7 @@
 #include "support.h"
 #include "util.h"
 #include <linux/smp_lock.h>
+#include <linux/bitops.h>
 
 static char I30[] = "$I30";
 
diff -u -urN linux-2.4.14-pre7-vanilla/include/linux/ntfs_fs.h linux-2.4.14-pre7-ntfs/include/linux/ntfs_fs.h
--- linux-2.4.14-pre7-vanilla/include/linux/ntfs_fs.h	Sat Sep  8 20:24:40 2001
+++ linux-2.4.14-pre7-ntfs/include/linux/ntfs_fs.h	Sat Nov  3 16:43:03 2001
@@ -10,12 +10,12 @@
  * Attribute flags (16-bit).
  */
 typedef enum {
-	ATTR_IS_COMPRESSED      = cpu_to_le16(0x0001),
-	ATTR_COMPRESSION_MASK   = cpu_to_le16(0x00ff),  /* Compression method
-							 * mask. Also, first
-							 * illegal value. */
-	ATTR_IS_ENCRYPTED       = cpu_to_le16(0x4000),
-	ATTR_IS_SPARSE          = cpu_to_le16(0x8000),
+	ATTR_IS_COMPRESSED      = __constant_cpu_to_le16(0x0001),
+	ATTR_COMPRESSION_MASK   = __constant_cpu_to_le16(0x00ff),
+					/* Compression method mask. Also,
+					 * first illegal value. */
+	ATTR_IS_ENCRYPTED       = __constant_cpu_to_le16(0x4000),
+	ATTR_IS_SPARSE          = __constant_cpu_to_le16(0x8000),
 } __attribute__ ((__packed__)) ATTR_FLAGS;
 
 /*


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] NTFS sparc compile fix
  2001-11-03 20:36 [PATCH] NTFS sparc compile fix Anton Altaparmakov
@ 2001-11-19  8:52 ` Albert D. Cahalan
  0 siblings, 0 replies; 2+ messages in thread
From: Albert D. Cahalan @ 2001-11-19  8:52 UTC (permalink / raw)
  To: Anton Altaparmakov; +Cc: torvalds, alan, linux-kernel

> Please apply below patchlet for your next releases (applies cleanly to
> any recent kernel). It fixes compilation of NTFS driver on Sparc.
...
> +	ATTR_IS_ENCRYPTED       = __constant_cpu_to_le16(0x4000),
> +	ATTR_IS_SPARSE          = __constant_cpu_to_le16(0x8000),

Can't SPARC be fixed with something like __builtin_constant_p() ?
It sure looks ugly to need __constant_cpu_to_le16() in a driver.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2001-11-19  8:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-11-03 20:36 [PATCH] NTFS sparc compile fix Anton Altaparmakov
2001-11-19  8:52 ` Albert D. Cahalan

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®