Code Review
/
deb_dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
New upstream version 17.11-rc3
[deb_dpdk.git]
/
drivers
/
bus
/
fslmc
/
mc
/
fsl_mc_sys.h
diff --git
a/drivers/bus/fslmc/mc/fsl_mc_sys.h
b/drivers/bus/fslmc/mc/fsl_mc_sys.h
index
ebada60
..
d803205
100644
(file)
--- a/
drivers/bus/fslmc/mc/fsl_mc_sys.h
+++ b/
drivers/bus/fslmc/mc/fsl_mc_sys.h
@@
-5,6
+5,7
@@
* BSD LICENSE
*
* Copyright 2013-2015 Freescale Semiconductor Inc.
* BSD LICENSE
*
* Copyright 2013-2015 Freescale Semiconductor Inc.
+ * Copyright 2017 NXP.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
@@
-65,40
+66,31
@@
struct fsl_mc_io {
#include <sys/uio.h>
#include <linux/byteorder/little_endian.h>
#include <sys/uio.h>
#include <linux/byteorder/little_endian.h>
-#define cpu_to_le64(x) __cpu_to_le64(x)
#ifndef dmb
#define dmb() {__asm__ __volatile__("" : : : "memory"); }
#endif
#ifndef dmb
#define dmb() {__asm__ __volatile__("" : : : "memory"); }
#endif
-#define __iormb()
dmb()
-#define __iowmb()
dmb()
-#define __arch_getq(a)
(*(volatile unsigned long
*)(a))
-#define __arch_putq(v, a)
(*(volatile unsigned long
*)(a) = (v))
-#define __arch_putq32(v, a)
(*(volatile unsigned in
t *)(a) = (v))
-#define readq(c)
\
+#define __iormb() dmb()
+#define __iowmb() dmb()
+#define __arch_getq(a)
(*(volatile uint64_t
*)(a))
+#define __arch_putq(v, a)
(*(volatile uint64_t
*)(a) = (v))
+#define __arch_putq32(v, a)
(*(volatile uint32_
t *)(a) = (v))
+#define readq(c) \
({ uint64_t __v = __arch_getq(c); __iormb(); __v; })
({ uint64_t __v = __arch_getq(c); __iormb(); __v; })
-#define writeq(v, c)
\
+#define writeq(v, c) \
({ uint64_t __v = v; __iowmb(); __arch_putq(__v, c); __v; })
#define writeq32(v, c) \
({ uint32_t __v = v; __iowmb(); __arch_putq32(__v, c); __v; })
({ uint64_t __v = v; __iowmb(); __arch_putq(__v, c); __v; })
#define writeq32(v, c) \
({ uint32_t __v = v; __iowmb(); __arch_putq32(__v, c); __v; })
-#define ioread64(_p) readq(_p)
-#define iowrite64(_v, _p) writeq(_v, _p)
-#define iowrite32(_v, _p) writeq32(_v, _p)
+#define ioread64(_p)
readq(_p)
+#define iowrite64(_v, _p)
writeq(_v, _p)
+#define iowrite32(_v, _p)
writeq32(_v, _p)
#define __iomem
#define __iomem
-struct fsl_mc_io {
- void *regs;
-};
-
-#ifndef ENOTSUP
-#define ENOTSUP 95
-#endif
-
/*GPP is supposed to use MC commands with low priority*/
#define CMD_PRI_LOW 0 /*!< Low Priority command indication */
/*GPP is supposed to use MC commands with low priority*/
#define CMD_PRI_LOW 0 /*!< Low Priority command indication */
-struct
mc_command;
-
-
int mc_send_command(struct fsl_mc_io *mc_io, struct mc_command *cmd)
;
+struct
fsl_mc_io {
+ void *regs;
+
}
;
#endif /* __linux_driver__ */
#endif /* __linux_driver__ */