wok-tiny view hardware-ibm-6272/receipt @ rev 94

Refresh, remove kernel*, add linux
author Pascal Bellard <pascal.bellard@slitaz.org>
date Fri Oct 02 21:45:05 2015 +0200 (2015-10-02)
parents
children 2c3b4f47fbf5
line source
1 # SliTaz package receipt.
3 PACKAGE="hardware-ibm-6272"
4 VERSION="1.0"
5 CATEGORY="meta"
6 MAINTAINER="devel@slitaz.org"
7 LICENSE="BSD"
8 SHORT_DESC="IBM 300GL 6272/6282 (P75-233 ISA/PCI/USB/ETH desktop) hardware support"
9 WEB_SITE="http://www.slitaz.org/"
11 DEPENDS="isapnptools module-cs89x0"
12 SUGGESTED="module-usb-storage"
14 # Post message when installing.
15 post_install()
16 {
17 [ -s $1/etc/init.d/pnp.sh ] || cat > $1/etc/init.d/pnp.sh <<EOT
18 #!/bin/sh
20 . /etc/init.d/rc.functions
21 EOT
22 chmod +x $fs/etc/init.d/pnp.sh
23 cat >> $1/etc/init.d/pnp.sh <<EOT
25 echo -n "Switching on isa pnp ethernet card "
26 for io in \$(seq 360 -10 250); do for irq in IRQ_CS89X0_LIST; do
27 pnpdump | awk "BEGIN {s=0} \\
28 /CONFIGURE CSC6040/ {s=1} { \\
29 if (s==0) print; \\
30 else if (/INT 0/) print \\"(INT 0 (IRQ \$irq (MODE +E)))\\"; \\
31 else if (/IO 0/) print \\"(IO 0 (SIZE 16) (BASE 0x0\$io) (CHECK))\\"; \\
32 else if (/ACT Y/) { s=0; print \\"(ACT Y)\\"} \\
33 else print \\
34 }" > /etc/isapnp.conf
35 if isapnp /etc/isapnp.conf > /dev/null 2>&1 ; then
36 modprobe cs89x0 io=0x\$io irq=\$irq > /dev/null 2>&1
37 break 2
38 fi
39 done ; done
40 status
41 EOT
42 grep pnp.sh $1/etc/rcS.conf ||
43 sed -i 's/EARLY_RUN_SCRIPTS="/&pnp.sh /' $1/etc/rcS.conf
44 list=""
45 for i in $IRQ_CS89X0_LIST ; do
46 case " 15 12 11 10 9 7 6 5 4 3 " in
47 *\ $i\ *) list="$list $i "
48 esac
49 done
50 sed -i "s/IRQ_CS89X0_LIST/${list:-15 12 11 10}/" $1/etc/init.d/pnp.sh
51 sed -i 's/cs89x0[^ "]* //' $1/etc/rcS.conf
52 }
54 config_form()
55 {
56 cat <<EOT
57 <table>
58 <tr>
59 <td>Allowed IRQ for the Ethernet driver cs89x0</td>
60 <td><input type="text" name="IRQ_CS89X0_LIST" value="${IRQ_LIST:-15 12 11 10 9 7 6 5 4 3}" /></td>
61 </tr>
62 </table>
63 EOT
64 }