-__u8 rdc3210_map_read8(struct map_info *map, unsigned long ofs)
-{
- return *(__u8 *)(map->map_priv_1 + ofs);
-}
-
-__u16 rdc3210_map_read16(struct map_info *map, unsigned long ofs)
-{
- return *(__u16 *)(map->map_priv_1 + ofs);
-}
-
-__u32 rdc3210_map_read32(struct map_info *map, unsigned long ofs)
-{
- return *(__u32 *)(map->map_priv_1 + ofs);
-}
-
-void rdc3210_map_write8(struct map_info *map, __u8 d, unsigned long adr)
-{
- *(__u8 *)(map->map_priv_1 + adr) = d;
-}
-
-void rdc3210_map_write16(struct map_info *map, __u16 d, unsigned long adr)
-{
- *(__u16 *)(map->map_priv_1 + adr) = d;
-}
-
-void rdc3210_map_write32(struct map_info *map, __u32 d, unsigned long adr)
-{
- *(__u32 *)(map->map_priv_1 + adr) = d;
-}
-
-void rdc3210_map_copy_from(struct map_info *map, void *to, unsigned long from, ssize_t len)
-{
- int i;
- u16 *dst = (u16 *)(to);
- u16 *src = (u16 *)(map->map_priv_1 + from);
-
- for(i = 0; i < (len / 2); ++i)
- dst[i] = src[i];
-
- if(len & 1)
- {
- printk("# WARNNING!!! rdc3210_map_copy_from has odd length\n");
- //dst[len - 1] = B0(src[i]);
- }
-}
-
-void rdc3210_map_copy_to(struct map_info *map, unsigned long to, const void *from, ssize_t len)
-{
- int i;
- u16 *dst = (u16 *)(map->map_priv_1 + to);
- u16 *src = (u16 *)(from);
-
- for(i = 0; i < (len / 2); ++i)
- dst[i] = src[i];
-
- if(len & 1)
- {
- printk("# WARNNING!!! rdc3210_map_copy_from has odd length\n");
- //dst[len - 1] = B0(src[i]);
- }
-}
-