]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
ieee1394: consolidate uses of IEEE1934_BUSID_MAGIC
authorHarvey Harrison <harvey.harrison@gmail.com>
Sat, 13 Dec 2008 05:57:50 +0000 (21:57 -0800)
committerStefan Richter <stefanr@s5r6.in-berlin.de>
Sun, 4 Jan 2009 22:50:34 +0000 (23:50 +0100)
Move the definition out of nodemgr.h and use it in csr.c/pcilynx.c

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
drivers/ieee1394/csr.c
drivers/ieee1394/ieee1394.h
drivers/ieee1394/nodemgr.h
drivers/ieee1394/pcilynx.c

index 9029b6839f0b8b07737952e70267391dad7e98c6..31400c8ae051553eead427979d056a3be80d248d 100644 (file)
@@ -217,7 +217,7 @@ static void add_host(struct hpsb_host *host)
 
        host->csr.generation = 2;
 
-       bus_info[1] = __constant_cpu_to_be32(0x31333934);
+       bus_info[1] = IEEE1394_BUSID_MAGIC;
        bus_info[2] = cpu_to_be32((hpsb_disable_irm ? 0 : 1 << CSR_IRMC_SHIFT) |
                                  (1 << CSR_CMC_SHIFT) |
                                  (1 << CSR_ISC_SHIFT) |
@@ -250,7 +250,7 @@ static void remove_host(struct hpsb_host *host)
 {
        quadlet_t bus_info[CSR_BUS_INFO_SIZE];
 
-       bus_info[1] = __constant_cpu_to_be32(0x31333934);
+       bus_info[1] = IEEE1394_BUSID_MAGIC;
        bus_info[2] = cpu_to_be32((0 << CSR_IRMC_SHIFT) |
                                  (0 << CSR_CMC_SHIFT) |
                                  (0 << CSR_ISC_SHIFT) |
index 40492074c013c9d42af0eda8f4363506ab32e1da..e0ae0d3d747ff1a9e053919bb887bebeadc21d98 100644 (file)
@@ -121,6 +121,9 @@ extern const char *hpsb_speedto_str[];
 
 #include <asm/byteorder.h>
 
+/* '1' '3' '9' '4' in ASCII */
+#define IEEE1394_BUSID_MAGIC   cpu_to_be32(0x31333934)
+
 #ifdef __BIG_ENDIAN_BITFIELD
 
 struct selfid {
index 4f287a3561ba9943b8ecc9c8e33963da15fba9b3..15ea09733e84fbc1ee4588f730ed77b049aa1e5c 100644 (file)
@@ -31,9 +31,6 @@ struct csr1212_keyval;
 struct hpsb_host;
 struct ieee1394_device_id;
 
-/* '1' '3' '9' '4' in ASCII */
-#define IEEE1394_BUSID_MAGIC   __constant_cpu_to_be32(0x31333934)
-
 /* This is the start of a Node entry structure. It should be a stable API
  * for which to gather info from the Node Manager about devices attached
  * to the bus.  */
index 7aee1ac97c80357c6633b0851d89465cab33e74c..dc15cadb06ef0b98ac4053f73e32d7e4e26028c9 100644 (file)
@@ -1463,7 +1463,7 @@ static int __devinit add_card(struct pci_dev *dev,
 
                                 /* info_length, crc_length and 1394 magic number to check, if it is really a bus info block */
                                if (((be32_to_cpu(lynx->bus_info_block[0]) & 0xffff0000) == 0x04040000) &&
-                                   (lynx->bus_info_block[1] == __constant_cpu_to_be32(0x31333934)))
+                                   (lynx->bus_info_block[1] == IEEE1394_BUSID_MAGIC))
                                 {
                                         PRINT(KERN_DEBUG, lynx->id, "read a valid bus info block from");
                                 } else {