Magellan Linux

Diff of /trunk/installer/hwdetection.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 575 by niro, Wed Sep 12 18:50:51 2007 UTC revision 576 by niro, Wed Sep 12 19:02:39 2007 UTC
# Line 16  get_hwinfo() Line 16  get_hwinfo()
16   local item="$1"   local item="$1"
17   local all   local all
18   local i   local i
19    
20     # handle special items
21     case ${item} in
22     memory) get_hwinfo_memory; return ;;
23     smp) get_hwinfo_smp; return ;;
24     esac
25    
26   all=$(hwinfo --short --"${item}")   all=$(hwinfo --short --"${item}")
27    
28   declare -i i=0   declare -i i=0
# Line 34  get_hwinfo() Line 41  get_hwinfo()
41   done <<< "${all}"   done <<< "${all}"
42  }  }
43    
44    
45    # special memory case
46    get_hwinfo_memory()
47    {
48     local memory=$(hwinfo --memory  | grep "Memory Size" | cut -d: -f2 | sed "s:\ ::")
49     echo "${memory}"
50    }
51    
52    
53    # special smp case
54    get_hwinfo_smp()
55    {
56     local smp=$(hwinfo --smp  | grep "SMP support:" | cut -d: -f2 | sed "s:\ ::")
57     echo "${smp}"
58    }
59    
60    
61  # get_driver_modules $hw_item  # get_driver_modules $hw_item
62  get_driver_modules()  get_driver_modules()
63  {  {

Legend:
Removed from v.575  
changed lines
  Added in v.576