mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

73 lines
2.0 KiB

  1. diff -ruN rockplug-0.0.9/Makefile rockplug-0.0.9-new/Makefile
  2. --- rockplug-0.0.9/Makefile 2004-03-22 07:08:30.000000000 +0100
  3. +++ rockplug-0.0.9-new/Makefile 2004-10-06 09:31:01.178453224 +0200
  4. @@ -1,5 +1,5 @@
  5. PACKAGE = rockplug
  6. -VERSION = 0.0.7
  7. +VERSION = 0.0.9
  8. SCRIPTS = \
  9. etc/rockplug/usb.init \
  10. @@ -19,6 +19,7 @@
  11. etc/rockplug/scsi.init \
  12. etc/rockplug/scsi.plug \
  13. etc/rockplug/ieee1394.plug \
  14. +etc/rockplug/firmware.plug \
  15. sbin/rockplug \
  16. sbin/rockscan
  17. diff -ruN rockplug-0.0.9/etc/rockplug/firmware.plug rockplug-0.0.9-new/etc/rockplug/firmware.plug
  18. --- rockplug-0.0.9/etc/rockplug/firmware.plug 1970-01-01 01:00:00.000000000 +0100
  19. +++ rockplug-0.0.9-new/etc/rockplug/firmware.plug 2004-10-06 09:30:32.561803616 +0200
  20. @@ -0,0 +1,51 @@
  21. +#!/bin/bash
  22. +# Copyright (C) 2003 Juergen "George" Sawinski
  23. +# Rene Rebe
  24. +# All rights reserved.
  25. +# Partially copied from/rewritten based on hotplug.
  26. +# See README file for further explanation and
  27. +# LICENCING TERMS (GPL v2 or later).
  28. +
  29. +. /etc/rockplug/functions
  30. +
  31. +# config
  32. +FIRMWARE_DIR=/usr/lib/rockplug/firmware
  33. +[ -f /etc/conf/firmware ] && . /etc/conf/firmware
  34. +
  35. +# sanity checks
  36. +if [ "$FIRMWARE" = "" -o "$ACTION" = "" -o "$DEVPATH" = ""]; then
  37. + #@FIXME meaningfull message
  38. + mesg "Invalid invocation of $0"
  39. + exit 1
  40. +fi
  41. +
  42. +SYSFS=$(sed -n 's/^.* \([^ ]*\) sysfs .*$/\1/p' /proc/mounts)
  43. +
  44. +# use /proc for 2.4 kernels
  45. +if [ "$SYSFS" = "" ]; then
  46. + SYSFS=/proc
  47. +fi
  48. +
  49. +case $ACTION in
  50. + add)
  51. + mesg "Firmware: Loading $FIRMWARE for $DEVPATH"
  52. + if [ -f $FIRMWARE_DIR/$FIRMWARE ]; then
  53. + echo 1 > $SYSFS/$DEVPATH/loading
  54. + cp $FIRMWARE_DIR/$FIRMWARE $SYSFS/$DEVPATH/data
  55. + echo 0 > $SYSFS/$DEVPATH/loading
  56. + else
  57. + echo -1 > $SYSFS/$DEVPATH/loading
  58. + fi
  59. + ;;
  60. + remove)
  61. + mesg "Firmware: Not removing anything"
  62. + ;;
  63. + *)
  64. + mesg "Firmware: Nothing to do for $ACTION"
  65. + ;;
  66. +esac
  67. +
  68. +# Local variables:
  69. +# mode: shell-script
  70. +# basic-offset: 2
  71. +# End: