Changeset 3040


Ignore:
Timestamp:
Jul 7, 2012, 4:18:02 AM (2 years ago)
Author:
wmb
Message:

OLPC - revert the SD node rearrangement portion of revision 3023, to fix Linux booting on older kernels (OLPC trac #11998).

Location:
cpu/arm/olpc
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • cpu/arm/olpc/build-fw.fth

    r3036 r3040  
    358358[then] 
    359359 
    360 devalias int /sd/sdhci@d4281000/disk 
    361 devalias ext /sd/sdhci@d4280000/disk 
     360devalias int /sd/disk@3 
     361devalias ext /sd/disk@1 
    362362devalias net /wlan  \ XXX should report-net in case of USB Ethernet 
    363363 
  • cpu/arm/olpc/sdhci.fth

    r3023 r3040  
    11purpose: Load file for SDHCI (Secure Digital Host Controller Interface) 
    22 
    3 0 0  " "  " /"  begin-package 
     30 0  " d4280000"  " /"  begin-package 
    44 
    55   fload ${BP}/cpu/arm/olpc/sdregs.fth 
    66   fload ${BP}/dev/mmc/sdhci/sdhci.fth 
    7  
    8    " simple-bus" +compatible 
    9    h# d4280000 encode-int  h# d4280000 encode-int encode+  h# 2000 encode-int encode+  " ranges" property 
    10    1 " #address-cells" integer-property 
    11    1 " #size-cells" integer-property 
    127 
    138   d# 1 to power-off-time  \ A2 and A3 have turn-off clamps 
     
    1510 
    1611   hex 
    17    : slot#  ( -- n )  slot h# d4280000 -  h# 800 /  1+  ; 
    1812   : olpc-card-inserted?  ( -- flag ) 
    19       slot# 1 =  if  d# 31 gpio-pin@ 0=  else  true  then 
     13      slot 1 =  if  d# 31 gpio-pin@ 0=  else  true  then 
    2014   ; 
    2115   ' olpc-card-inserted? to card-inserted? 
     
    2519      sdhci-card-power-on 
    2620\ The CL3 version below actually works for CL2 >= B1 
    27 \+ olpc-cl2  d# 36 slot# - gpio-set 
    28 \+ olpc-cl3  slot# 2 =  if  d# 34 gpio-set  then 
     21\+ olpc-cl2  d# 36 slot - gpio-set 
     22\+ olpc-cl3  slot 2 =  if  d# 34 gpio-set  then 
    2923   ; 
    3024   ' gpio-power-on to card-power-on 
    3125 
    3226   : gpio-power-off  ( -- ) 
    33 \+ olpc-cl2  d# 36 slot# - gpio-clr 
    34 \+ olpc-cl3  slot# 2 =  if  d# 34 gpio-clr  then 
     27\+ olpc-cl2  d# 36 slot - gpio-clr 
     28\+ olpc-cl3  slot 2 =  if  d# 34 gpio-clr  then 
    3529      sdhci-card-power-off 
    3630   ; 
     
    3832 
    3933\+ olpc-cl2   new-device 
    40 \+ olpc-cl2      h# d428.0000 h# 800 reg 
    41 \+ olpc-cl2      8 encode-int " bus-width" property 
    42 \+ olpc-cl2      " mrvl,pxav3-mmc" encode-string  " compatible" property 
    43 \+ olpc-cl2      d# 31 encode-int " clk-delay-cycles" property 
    44 \+ olpc-cl2      fload ${BP}/dev/mmc/sdhci/slot.fth 
    45 \+ olpc-cl2      d# 39 " interrupts" integer-property 
    46  
    47 \+ olpc-cl2      " /pmua" encode-phandle 3 encode-int encode+ " clocks" property 
    48 \+ olpc-cl2      " PXA-SDHCLK" " clock-names" string-property 
    49  
    50 \+ olpc-cl2      new-device 
    51 \+ olpc-cl2         fload ${BP}/dev/mmc/sdhci/sdmmc.fth 
    52 \+ olpc-cl2         fload ${BP}/dev/mmc/sdhci/selftest.fth 
    53 \+ olpc-cl2         " external" " slot-name" string-property 
    54 \+ olpc-cl2      finish-device 
     34\+ olpc-cl2      1 encode-int " reg" property 
     35\+ olpc-cl2      fload ${BP}/dev/mmc/sdhci/sdmmc.fth 
     36\+ olpc-cl2      fload ${BP}/dev/mmc/sdhci/selftest.fth 
     37\+ olpc-cl2      " external" " slot-name" string-property 
    5538\+ olpc-cl2   finish-device 
    5639 
    5740   new-device 
    58       h# d428.0800 h# 800 reg 
    59       8 encode-int " bus-width" property 
    60       " sdhci-pxav3" +compatible 
    61       " mrvl,pxav3-mmc" +compatible 
    62       d# 31 encode-int " clk-delay-cycles" property 
    63       0 0  " non-removable" property 
    64       d# 52 " interrupts" integer-property 
    65  
    66       " /pmua" encode-phandle 4 encode-int encode+ " clocks" property 
    67       " PXA-SDHCLK" " clock-names" string-property 
    68  
    69       fload ${BP}/dev/mmc/sdhci/slot.fth 
    70       new-device 
    71          fload ${BP}/dev/mmc/sdhci/mv8686/loadpkg.fth 
    72       finish-device 
     41      2 encode-int " reg" property 
     42      fload ${BP}/dev/mmc/sdhci/mv8686/loadpkg.fth 
    7343   finish-device 
    7444 
    7545   new-device 
    76       h# d428.1000 h# 800 reg 
    77       0 0  " non-removable" property 
    78       8 encode-int " bus-width" property 
    79       " sdhci-pxav3" +compatible 
    80       " mrvl,pxav3-mmc" +compatible 
    81       d# 31 encode-int " clk-delay-cycles" property 
    82       d# 53 " interrupts" integer-property 
    83  
    84       " /pmua" encode-phandle d# 14 encode-int encode+ " clocks" property 
    85       " PXA-SDHCLK" " clock-names" string-property 
    86  
    87       fload ${BP}/dev/mmc/sdhci/slot.fth 
    88       new-device 
    89          fload ${BP}/dev/mmc/sdhci/sdmmc.fth 
    90          fload ${BP}/dev/mmc/sdhci/selftest.fth 
    91          " internal" " slot-name" string-property 
    92       finish-device 
     46      3 encode-int " reg" property 
     47      fload ${BP}/dev/mmc/sdhci/sdmmc.fth 
     48      fload ${BP}/dev/mmc/sdhci/selftest.fth 
     49      " internal" " slot-name" string-property 
    9350   finish-device 
    9451 
  • cpu/arm/olpc/sdregs.fth

    r3023 r3040  
    550 instance value chip 
    66 
    7 \ my-space /regs  reg 
     7my-space /regs  reg 
    88 
    99: map-regs  ( -- ) 
    1010   chip  if  exit  then 
    11    slot /regs " map-in" $call-parent 
     11   slot 1-  h# 800 *  my-space + /regs " map-in" $call-parent 
    1212   to chip 
    1313; 
Note: See TracChangeset for help on using the changeset viewer.