====== spufs-change-llx-to-0x-llx.diff ====== Subject: [PATCH 2.6.18] spufs: Change %llx to 0x%llx. From: Dwayne Grant McConnell This patches changes /npc, /decr, /decr_status, /spu_tag_mask, /event_mask, /event_status, and /srr0 files to provide output according to the format string "0x%llx" instead of "%llx". Before this patch some files used "0x%llx" and other used "%llx" which is inconsistent and potentially confusing. A user might assume "%llx" numbers were decimal if they happened to not contain any a-f digits. This change will break any code cannot tolerate a leading 0x in the file contents. The only known users of these files are the libspe but there might also be some scripts which access these files. This risk is deemed acceptable for future consistency. Signed-off-by: Dwayne Grant McConnell -- Dwayne Grant McConnell Lotus Notes Mail: Dwayne McConnell [Mail]/Austin/IBM@IBMUS Lotus Notes Calendar: Dwayne McConnell [Calendar]/Austin/IBM@IBMUS --- diffstat: file.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) ====== spufs-gdb-interfaces-addon-5.diff ====== Subject: spufs: add /lslr, /dma_info and /proxydma files From: Dwayne Grant McConnell The /lslr file gives read access to the SPU_LSLR register in hex; 0x3fff for example The /dma_info file provides read access to the SPU Command Queue in a binary format. The /proxydma_info files provides read access access to the Proxy Command Queue in a binary format. The spu_info.h file provides data structures for interpreting the binary format of /dma_info and /proxydma_info. Signed-off-by: Dwayne Grant McConnell Signed-off-by: Arnd Bergmann --- diffstat: arch/powerpc/platforms/cell/spufs/backing_ops.c | 1 arch/powerpc/platforms/cell/spufs/file.c | 133 +++++++++- arch/powerpc/platforms/cell/spufs/spufs.h | 9 include/asm-powerpc/Kbuild | 1 include/asm-powerpc/spu_info.h | 54 ++++ 5 files changed, 192 insertions(+), 6 deletions(-) ====== spufs-remove-spu_tag_mask.diff ====== Subject: [PATCH 2.6.18] spufs: Remove /spu_tag_mask file From: Dwayne Grant McConnell This patch removes the /spu_tag_mask file from spufs. The data provided by this file is also available from the /dma_info file in the dma_info_mask of the spu_dma_info struct. The file was intended to be used by gdb, but that never used it, and now it has been replaced with the more verbose dma_info file. Signed-off-by: Dwayne Grant McConnell Signed-off-by: Arnd Bergmann --- diffstat: file.c | 23 ----------------------- 1 file changed, 23 deletions(-) ====== spufs-mbox-info.diff ====== Subject: [PATCH 2.6.18] spufs: implement /mbox_info, /ibox_info, and /wbox_info. From: Dwayne Grant McConnell This patch implements read only access to /mbox_info - SPU Write Outbound Mailbox /ibox_info - SPU Write Outbound Interrupt Mailbox /wbox_info - SPU Read Inbound Mailbox These files are used by gdb in order to look into the current mailbox queues without changing the contents at the same time. They are not meant for general programming use, since the access requires a context save and is therefore rather slow. It would be good to complement this patch with one that adds write support as well. Signed-off-by: Dwayne Grant McConnell -- Dwayne Grant McConnell Lotus Notes Mail: Dwayne McConnell [Mail]/Austin/IBM@IBMUS Lotus Notes Calendar: Dwayne McConnell [Calendar]/Austin/IBM@IBMUS --- diffstat: file.c | 90 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) ====== spufs-require-context-save-for-signal-read-2.diff ====== Subject: spufs: read from signal files only if data is there From: Dwayne Grant McConnell We need to check the channel count of the signal notification registers before reading them, because it can be undefined when the count is zero. In order to read count and data atomically, we read from the saved context. This patch uses spu_acquire_saved() to force a context save before a /signal1 or /signal2 read. Because of this it is no longer necessary to have backing_ops and hw_ops versions of this function so they have been removed. Regular applications should not rely on reading this register to be fast, as it's conceptually a write-only file from the PPE perspective. Signed-off-by: Dwayne Grant McConnell -- Dwayne Grant McConnell Lotus Notes Mail: Dwayne McConnell [Mail]/Austin/IBM@IBMUS Lotus Notes Calendar: Dwayne McConnell [Calendar]/Austin/IBM@IBMUS --- diffstat: file.c | 30 ++++++++++++++++++++++-------- hw_ops.c | 12 ------------ 2 files changed, 22 insertions(+), 20 deletions(-) ====== spufs-vm-io-mappings.diff ====== Subject: spufs: avoid user-triggered oops in ptrace From: Christoph Hellwig When one of the spufs files is mapped into a process address space, regular users can use ptrace to attempt accessing them with access_process_vm(). With the way that the mappings currently work, this likely causes an oops. Setting the vm_flags to VM_IO makes sure that ptrace can not access them but returns an error code. This is not the perfect solution in case of the local store mapping, but it fixes the oops in a well-defined way. Signed-off-by: Arnd Bergmann --- diffstat: file.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) ====== spufs-fixme.diff ====== Subject: spufs: add a FIXME SetPageReserved should probably not be called on vmalloc memory. Need to investigate further. Signed-off-by: Arnd Bergmann --- --- diffstat: switch.c | 1 + 1 file changed, 1 insertion(+) ====== coredump-add-spu-elf-notes.diff ====== Subject: [PATCH 2.6.18] coredump: Add SPU elf notes to coredump. From: Dwayne Grant McConnell This patch adds SPU elf notes to the coredump. It creates a separate note for each of /regs, /fpcr, /lslr, /decr, /decr_status, /mem, /signal1, /signal1_type, /signal2, /signal2_type, /event_mask, /event_status, /mbox_info, /ibox_info, /wbox_info, /dma_info, /proxydma_info, /object-id. A new macro, ELF_CORE_EXTRA_NOTES_SIZE, was created so the size of the additional notes could be calculated and added to the notes phdr entry. A new macro, ELF_CORE_WRITE_EXTRA_NOTES, was created so the new notes would be written after the existing notes. Signed-off-by: Dwayne Grant McConnell Signed-off-by: Arnd Bergmann This is just preliminary, the file handling will have to be done differently to avoid calling syscalls from the core dump path, and we need to watch out for nonschedulable contexts. It's not clear yet how the best integration into the common core dump code should look like. Arnd <>< --- diffstat: arch/powerpc/platforms/cell/Makefile | 1 arch/powerpc/platforms/cell/spu_coredump.c | 251 ++++++++++ fs/binfmt_elf.c | 12 include/asm-powerpc/elf.h | 13 4 files changed, 277 insertions(+) ====== coredump-add-spu-elf-notes-fix.diff ====== Subject: Fix spu core dump contents From: Ulrich Weigand Signed-off-by: Arnd Bergmann --- diffstat: spu_coredump.c | 55 ++++++++++++++----------------------- 1 file changed, 22 insertions(+), 33 deletions(-)