10 #include <linux/kernel.h>
11 #include <linux/module.h>
20 if (((
unsigned long)dst & 3) != ((
unsigned long)src & 3))
22 while ((
unsigned long)dst & 3) {
23 writeb(*(
char *)src, dst++);
35 writeb(*(
char *)src, dst++);
56 if ( (((
unsigned long)dst ^ (
unsigned long)src) & 1) || (count < 2) )
59 if ( (((
unsigned long)dst ^ (
unsigned long)src) & 2) || (count < 4) )
63 if ((
unsigned long)src & 1) {
68 if (count < 2)
goto bytecopy;
71 if ((
unsigned long)src & 2) {
95 *(
char *)dst =
readb(src);
107 u32 val32 = (val << 24) | (val << 16) | (val << 8) | val;
108 while ((
unsigned long)addr & 3) {
130 p = (
unsigned char *)dst;
132 while (((
unsigned long)p) & 0x3) {
144 w |=
inb(port) << 16;
147 *(
unsigned int *) p = w;
168 unsigned int l = 0,
l2;
171 p = (
unsigned char *)dst;
176 switch (((
unsigned long)p) & 0x3)
184 *(
unsigned int *)p = l;
201 *(
unsigned int *)p = l;
221 *(
unsigned short *)p = (l & 0xff) << 8 | (
l2 >> 8);
240 unsigned int l = 0,
l2;
243 p = (
unsigned char *)dst;
248 switch (((
unsigned long) dst) & 0x3)
262 *(
unsigned short *)p = l >> 16;
268 *(
unsigned int *)p = (l & 0xffff) << 16 | (
l2 >> 16);
272 *(
unsigned short *)p = l & 0xffff;
278 *(
unsigned char *)p = l >> 24;
280 *(
unsigned short *)p = (l >> 8) & 0xffff;
285 *(
unsigned int *)p = (l & 0xff) << 24 | (
l2 >> 8);
300 *(
unsigned int *)p = (l & 0xffffff) << 8 |
l2 >> 24;
304 *(
unsigned short *)p = (l >> 8) & 0xffff;
320 const unsigned char *
p;
322 p = (
const unsigned char *)src;
338 unsigned int l = 0,
l2;
339 const unsigned char *
p;
341 p = (
const unsigned char *)src;
346 switch (((
unsigned long)p) & 0x3)
351 l = *(
unsigned int *)p;
369 l = *(
unsigned int *)p;
389 l2 = *(
unsigned short *)p;
394 l2 = *(
unsigned char *)p;
410 unsigned int l = 0,
l2;
411 const unsigned char *
p;
413 p = (
const unsigned char *)src;
418 switch (((
unsigned long)p) & 0x3)
431 l = *(
unsigned short *)p;
436 l2 = *(
unsigned int *)p;
441 l2 = *(
unsigned short *)p;
449 l |= *(
unsigned short *)p << 8;
454 l2 = *(
unsigned int *)p;
470 l2 = *(
unsigned int *)p;
475 l2 = *(
unsigned short *)p << 16;