Bug#483399: initscript: Support Cell processor spufs
reassign 483399 libspe2 thanks No-one replied to my email dated 2008-06-06 to explain why this behaviour could not be implemented in libspe2, so I assume this is the bets place for the Cell support, and reassign this bug report there. Happy hacking, -- Petter Reinholdtsen -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#483399: initscript: Support Cell processor spufs
[Arthur Loiret] I think the groupadd and mkdir things should rather be in libspe2's postinst than in an initscript at all, but it sounds better to keep the mount commands with appropriated tests in initscripts package. This would indeed avoid having to create a new cell-specific initscript. Petter, are you ok with this? I must admit that I prefer to keep the generic stuff in initscripts, and leave the special case handling in other packages. It make the initscripts package easier to maintain, and also we avoid running code on all machines that is only used on some of them. Are you ok with including it in libspe2? This is not a strong preference, though, so if it make most sense to do this mounting in the generic scripts, we can do that. Btw, how early must this file system be mounted? Is it OK to do it in rc2.d/, instead of rcS.d/? It is a good idea to do as little as possible in rcS.d/, to make sure single user mode is affected by as little as possible in case of errors in modules and services. Happy hacking, -- Petter Reinholdtsen -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#483399: initscript: Support Cell processor spufs
Hi, On Thu, May 29, 2008 at 06:52:23PM +0200, Martin Pitt wrote: Hi Petter, Petter Reinholdtsen [2008-05-29 18:04 +0200]: Thank you for the patch. Why should this be done in the initscripts package, and not in some cell specific package? I would otherwise believe it would fit better elsewhere, in a package only installed on this hardware. Right. However, last time I looked at it, an init script to mount /spu would be the only thing in such a hypothetical spu-support package. It could be built by the libspe2 source package [1], which would be indeed a bit more elegant, but quite expensive for a mere mount. A competely separate init script doesn't come for free in terms of boot speed, disk usage, etc. I CC'ed Arthur, the maintainer of libspe2 in Debian, who should have a better idea of how all this fits together. Arthur, any thoughts on this? I think the groupadd and mkdir things should rather be in libspe2's postinst than in an initscript at all, but it sounds better to keep the mount commands with appropriated tests in initscripts package. This would indeed avoid having to create a new cell-specific initscript. Petter, are you ok with this? Thank, Arthur. signature.asc Description: Digital signature
Bug#483399: [Pkg-sysvinit-devel] Bug#483399: initscript: Support Cell processor spufs
[Martin Pitt] Attached patch provides support for the Cell processor's SPU virtual kernel file system [1]. This is e. g. found on the Sony PlayStation 3. Thank you for the patch. Why should this be done in the initscripts package, and not in some cell specific package? I would otherwise believe it would fit better elsewhere, in a package only installed on this hardware. Happy hacking, -- Petter Reinholdtsen -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#483399: initscript: Support Cell processor spufs
Hi Petter, Petter Reinholdtsen [2008-05-29 18:04 +0200]: Thank you for the patch. Why should this be done in the initscripts package, and not in some cell specific package? I would otherwise believe it would fit better elsewhere, in a package only installed on this hardware. Right. However, last time I looked at it, an init script to mount /spu would be the only thing in such a hypothetical spu-support package. It could be built by the libspe2 source package [1], which would be indeed a bit more elegant, but quite expensive for a mere mount. A competely separate init script doesn't come for free in terms of boot speed, disk usage, etc. I CC'ed Arthur, the maintainer of libspe2 in Debian, who should have a better idea of how all this fits together. Arthur, any thoughts on this? Thank you! Martin [1] http://packages.qa.debian.org/libs/libspe2.html -- Martin Pitt| http://www.piware.de Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org) signature.asc Description: Digital signature
Bug#483399: initscript: Support Cell processor spufs
Package: initscripts Version: 2.86.ds1-56 Severity: wishlist Tags: patch User: [EMAIL PROTECTED] Usertags: origin-ubuntu intrepid ubuntu-patch Hi! Attached patch provides support for the Cell processor's SPU virtual kernel file system [1]. This is e. g. found on the Sony PlayStation 3. Thanks for considering, Martin [1] http://www.research.ibm.com/cell/SPU.html -- Martin Pitt| http://www.piware.de Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org) * Support Cell processor: - debian/initscripts/postinst: Create spu system group and /spu mount point if we are running on a Cell processor. - debian/initscripts/etc/init.d/mountkernfs.sh: Mount spufs if Cell processor is detected. - debian/control: Add initscripts dependency 'passwd' for groupadd. --- sysvinit-2.86.ds1/debian/control +++ sysvinit-2.86.ds1/debian/control @@ -48,7 +49,7 @@ Package: initscripts Architecture: any -Depends: ${shlibs:Depends}, ${glibc:Depends}, ${mount:Depends}, e2fsprogs (= 1.32+1.33-WIP-2003.04.14-1), debianutils (= 2.13.1), lsb-base (= 3.0-6), sysvinit-utils (= 2.86.ds1-39) +Depends: ${shlibs:Depends}, ${glibc:Depends}, ${mount:Depends}, e2fsprogs (= 1.32+1.33-WIP-2003.04.14-1), debianutils (= 2.13.1), lsb-base (= 3.0-6), sysvinit-utils (= 2.86.ds1-39), passwd Recommends: psmisc Conflicts: sysv-rc ( 2.86.ds1-1.2), sysvinit ( 2.86.ds1-12), udev ( 0.080-1), usplash ( 0.5.8-2), libdevmapper1.02.1 ( 2:1.02.24-1), insserv ( 1.09.0-12) Replaces: sysvinit ( 2.85-12), libc6, libc6.1, libc0.1, libc0.3 --- sysvinit-2.86.ds1/debian/initscripts/postinst +++ sysvinit-2.86.ds1/debian/initscripts/postinst @@ -197,6 +212,20 @@ fi # +# Create mount point for spufs, and create spu system group +# +if mountpoint -q /proc grep -qs '^cpu.*Cell' /proc/cpuinfo; then + if ! getent group spu /dev/null; then + # the adduser package is priority important; cannot use addgroup + groupadd -K GID_MAX=1000 spu + fi + mkdir -p /spu + if ! mountpoint -q /spu; then + mount -t spufs -ogid=spu spufs /spu + fi +fi + +# # Create initial log files # [ $PREV_VER ] || chmod 755 /var/log/fsck || : --- sysvinit-2.86.ds1/debian/initscripts/etc/init.d/mountkernfs.sh 2008-05-28 18:23:56.0 +0200 +++ sysvinit-2.86.ds1.new/debian/initscripts/etc/init.d/mountkernfs.sh 2008-05-28 18:23:38.0 +0200 @@ -74,6 +74,11 @@ then domount usbfs usbdevfs /proc/bus/usb usbfs -onodev,noexec,nosuid fi + + # Mount spufs, if Cell Broadband processor is detected + if [ -d /spu ] grep -qs '^cpu.*Cell' /proc/cpuinfo; then + domount spufs /spu -ogid=spu + fi } case $1 in signature.asc Description: Digital signature