diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-12 00:55:47 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-12 00:55:47 -0400 |
commit | e86908614f2c7fec401827e5cefd7a6ea9407f85 (patch) | |
tree | fcb5d9e52422b37bdaf0e647126ebdfc1680f162 /arch/powerpc/platforms/iseries/mf.c | |
parent | 547307420931344a868275bd7ea7a30f117a15a9 (diff) | |
parent | 9b4b8feb962f4b3e74768b7205f1f8f6cce87238 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (408 commits)
[POWERPC] Add memchr() to the bootwrapper
[POWERPC] Implement logging of unhandled signals
[POWERPC] Add legacy serial support for OPB with flattened device tree
[POWERPC] Use 1TB segments
[POWERPC] XilinxFB: Allow fixed framebuffer base address
[POWERPC] XilinxFB: Add support for custom screen resolution
[POWERPC] XilinxFB: Use pdata to pass around framebuffer parameters
[POWERPC] PCI: Add 64-bit physical address support to setup_indirect_pci
[POWERPC] 4xx: Kilauea defconfig file
[POWERPC] 4xx: Kilauea DTS
[POWERPC] 4xx: Add AMCC Kilauea eval board support to platforms/40x
[POWERPC] 4xx: Add AMCC 405EX support to cputable.c
[POWERPC] Adjust TASK_SIZE on ppc32 systems to 3GB that are capable
[POWERPC] Use PAGE_OFFSET to tell if an address is user/kernel in SW TLB handlers
[POWERPC] 85xx: Enable FP emulation in MPC8560 ADS defconfig
[POWERPC] 85xx: Killed <asm/mpc85xx.h>
[POWERPC] 85xx: Add cpm nodes for 8541/8555 CDS
[POWERPC] 85xx: Convert mpc8560ads to the new CPM binding.
[POWERPC] mpc8272ads: Remove muram from the CPM reg property.
[POWERPC] Make clockevents work on PPC601 processors
...
Fixed up conflict in Documentation/powerpc/booting-without-of.txt manually.
Diffstat (limited to 'arch/powerpc/platforms/iseries/mf.c')
-rw-r--r-- | arch/powerpc/platforms/iseries/mf.c | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/arch/powerpc/platforms/iseries/mf.c b/arch/powerpc/platforms/iseries/mf.c index b1187d95e3b2..c0f2433bc16e 100644 --- a/arch/powerpc/platforms/iseries/mf.c +++ b/arch/powerpc/platforms/iseries/mf.c | |||
@@ -39,9 +39,9 @@ | |||
39 | #include <asm/paca.h> | 39 | #include <asm/paca.h> |
40 | #include <asm/abs_addr.h> | 40 | #include <asm/abs_addr.h> |
41 | #include <asm/firmware.h> | 41 | #include <asm/firmware.h> |
42 | #include <asm/iseries/vio.h> | ||
43 | #include <asm/iseries/mf.h> | 42 | #include <asm/iseries/mf.h> |
44 | #include <asm/iseries/hv_lp_config.h> | 43 | #include <asm/iseries/hv_lp_config.h> |
44 | #include <asm/iseries/hv_lp_event.h> | ||
45 | #include <asm/iseries/it_lp_queue.h> | 45 | #include <asm/iseries/it_lp_queue.h> |
46 | 46 | ||
47 | #include "setup.h" | 47 | #include "setup.h" |
@@ -870,8 +870,7 @@ static int proc_mf_dump_cmdline(char *page, char **start, off_t off, | |||
870 | if ((off + count) > 256) | 870 | if ((off + count) > 256) |
871 | count = 256 - off; | 871 | count = 256 - off; |
872 | 872 | ||
873 | dma_addr = dma_map_single(iSeries_vio_dev, page, off + count, | 873 | dma_addr = iseries_hv_map(page, off + count, DMA_FROM_DEVICE); |
874 | DMA_FROM_DEVICE); | ||
875 | if (dma_mapping_error(dma_addr)) | 874 | if (dma_mapping_error(dma_addr)) |
876 | return -ENOMEM; | 875 | return -ENOMEM; |
877 | memset(page, 0, off + count); | 876 | memset(page, 0, off + count); |
@@ -883,8 +882,7 @@ static int proc_mf_dump_cmdline(char *page, char **start, off_t off, | |||
883 | vsp_cmd.sub_data.kern.length = off + count; | 882 | vsp_cmd.sub_data.kern.length = off + count; |
884 | mb(); | 883 | mb(); |
885 | rc = signal_vsp_instruction(&vsp_cmd); | 884 | rc = signal_vsp_instruction(&vsp_cmd); |
886 | dma_unmap_single(iSeries_vio_dev, dma_addr, off + count, | 885 | iseries_hv_unmap(dma_addr, off + count, DMA_FROM_DEVICE); |
887 | DMA_FROM_DEVICE); | ||
888 | if (rc) | 886 | if (rc) |
889 | return rc; | 887 | return rc; |
890 | if (vsp_cmd.result_code != 0) | 888 | if (vsp_cmd.result_code != 0) |
@@ -919,8 +917,7 @@ static int mf_getVmlinuxChunk(char *buffer, int *size, int offset, u64 side) | |||
919 | int len = *size; | 917 | int len = *size; |
920 | dma_addr_t dma_addr; | 918 | dma_addr_t dma_addr; |
921 | 919 | ||
922 | dma_addr = dma_map_single(iSeries_vio_dev, buffer, len, | 920 | dma_addr = iseries_hv_map(buffer, len, DMA_FROM_DEVICE); |
923 | DMA_FROM_DEVICE); | ||
924 | memset(buffer, 0, len); | 921 | memset(buffer, 0, len); |
925 | memset(&vsp_cmd, 0, sizeof(vsp_cmd)); | 922 | memset(&vsp_cmd, 0, sizeof(vsp_cmd)); |
926 | vsp_cmd.cmd = 32; | 923 | vsp_cmd.cmd = 32; |
@@ -938,7 +935,7 @@ static int mf_getVmlinuxChunk(char *buffer, int *size, int offset, u64 side) | |||
938 | rc = -ENOMEM; | 935 | rc = -ENOMEM; |
939 | } | 936 | } |
940 | 937 | ||
941 | dma_unmap_single(iSeries_vio_dev, dma_addr, len, DMA_FROM_DEVICE); | 938 | iseries_hv_unmap(dma_addr, len, DMA_FROM_DEVICE); |
942 | 939 | ||
943 | return rc; | 940 | return rc; |
944 | } | 941 | } |
@@ -1149,8 +1146,7 @@ static int proc_mf_change_cmdline(struct file *file, const char __user *buffer, | |||
1149 | goto out; | 1146 | goto out; |
1150 | 1147 | ||
1151 | dma_addr = 0; | 1148 | dma_addr = 0; |
1152 | page = dma_alloc_coherent(iSeries_vio_dev, count, &dma_addr, | 1149 | page = iseries_hv_alloc(count, &dma_addr, GFP_ATOMIC); |
1153 | GFP_ATOMIC); | ||
1154 | ret = -ENOMEM; | 1150 | ret = -ENOMEM; |
1155 | if (page == NULL) | 1151 | if (page == NULL) |
1156 | goto out; | 1152 | goto out; |
@@ -1170,7 +1166,7 @@ static int proc_mf_change_cmdline(struct file *file, const char __user *buffer, | |||
1170 | ret = count; | 1166 | ret = count; |
1171 | 1167 | ||
1172 | out_free: | 1168 | out_free: |
1173 | dma_free_coherent(iSeries_vio_dev, count, page, dma_addr); | 1169 | iseries_hv_free(count, page, dma_addr); |
1174 | out: | 1170 | out: |
1175 | return ret; | 1171 | return ret; |
1176 | } | 1172 | } |
@@ -1190,8 +1186,7 @@ static ssize_t proc_mf_change_vmlinux(struct file *file, | |||
1190 | goto out; | 1186 | goto out; |
1191 | 1187 | ||
1192 | dma_addr = 0; | 1188 | dma_addr = 0; |
1193 | page = dma_alloc_coherent(iSeries_vio_dev, count, &dma_addr, | 1189 | page = iseries_hv_alloc(count, &dma_addr, GFP_ATOMIC); |
1194 | GFP_ATOMIC); | ||
1195 | rc = -ENOMEM; | 1190 | rc = -ENOMEM; |
1196 | if (page == NULL) { | 1191 | if (page == NULL) { |
1197 | printk(KERN_ERR "mf.c: couldn't allocate memory to set vmlinux chunk\n"); | 1192 | printk(KERN_ERR "mf.c: couldn't allocate memory to set vmlinux chunk\n"); |
@@ -1219,7 +1214,7 @@ static ssize_t proc_mf_change_vmlinux(struct file *file, | |||
1219 | *ppos += count; | 1214 | *ppos += count; |
1220 | rc = count; | 1215 | rc = count; |
1221 | out_free: | 1216 | out_free: |
1222 | dma_free_coherent(iSeries_vio_dev, count, page, dma_addr); | 1217 | iseries_hv_free(count, page, dma_addr); |
1223 | out: | 1218 | out: |
1224 | return rc; | 1219 | return rc; |
1225 | } | 1220 | } |