=============================================================================== 4000274c : const char *rtems_bsp_cmdline_get_param( const char *name, char *value, size_t length ) { 4000274c: 9d e3 bf a0 save %sp, -96, %sp const char *p; if ( !name ) return NULL; if ( !value ) 40002750: 80 a0 00 19 cmp %g0, %i1 40002754: 84 60 3f ff subx %g0, -1, %g2 return NULL; if ( !length ) 40002758: 80 a0 00 1a cmp %g0, %i2 4000275c: 82 60 3f ff subx %g0, -1, %g1 40002760: 80 90 80 01 orcc %g2, %g1, %g0 40002764: 12 80 00 30 bne 40002824 40002768: 80 a6 20 00 cmp %i0, 0 4000276c: 02 80 00 2e be 40002824 40002770: 01 00 00 00 nop return NULL; value[0] = '\0'; 40002774: c0 2e 40 00 clrb [ %i1 ] p = rtems_bsp_cmdline_get_param_raw( name ); 40002778: 40 00 00 2d call 4000282c 4000277c: 90 10 00 18 mov %i0, %o0 if ( !p ) 40002780: 80 a2 20 00 cmp %o0, 0 40002784: 02 80 00 28 be 40002824 40002788: 01 00 00 00 nop for (i=0 ; *p && i <== NEVER TAKEN 4000279c: b4 86 bf ff addcc %i2, -1, %i2 400027a0: 02 80 00 1f be 4000281c <== NEVER TAKEN 400027a4: 82 10 20 00 clr %g1 quotes=0; 400027a8: 10 80 00 11 b 400027ec 400027ac: 88 10 20 00 clr %g4 } else if ( ((quotes % 2) == 0) && *p == ' ' ) 400027b0: 12 80 00 04 bne 400027c0 400027b4: 80 a0 a0 20 cmp %g2, 0x20 400027b8: 02 80 00 19 be 4000281c 400027bc: 01 00 00 00 nop value[i++] = *p++; 400027c0: c6 2e 40 01 stb %g3, [ %i1 + %g1 ] 400027c4: 82 00 60 01 inc %g1 value[i] = '\0'; 400027c8: c0 2e 40 01 clrb [ %i1 + %g1 ] for (i=0 ; *p && i 400027dc: 01 00 00 00 nop 400027e0: 80 a6 80 01 cmp %i2, %g1 400027e4: 02 80 00 0e be 4000281c 400027e8: 01 00 00 00 nop if ( *p == '\"' ) { 400027ec: 85 38 a0 18 sra %g2, 0x18, %g2 400027f0: 80 a0 a0 22 cmp %g2, 0x22 400027f4: 12 bf ff ef bne 400027b0 400027f8: 80 89 20 01 btst 1, %g4 value[i++] = *p++; 400027fc: c6 2e 40 01 stb %g3, [ %i1 + %g1 ] 40002800: 82 00 60 01 inc %g1 value[i] = '\0'; 40002804: c0 2e 40 01 clrb [ %i1 + %g1 ] for (i=0 ; *p && i <== ALWAYS TAKEN 40002818: 88 01 20 01 inc %g4 return NULL; 4000281c: 81 c7 e0 08 ret 40002820: 91 e8 00 19 restore %g0, %i1, %o0 return NULL; copy_string( p, value, length ); return value; } 40002824: 81 c7 e0 08 ret 40002828: 91 e8 20 00 restore %g0, 0, %o0 =============================================================================== 4000285c : const char *rtems_bsp_cmdline_get_param_rhs( const char *name, char *value, size_t length ) { 4000285c: 9d e3 bf a0 save %sp, -96, %sp const char *p; const char *rhs; char *d; p = rtems_bsp_cmdline_get_param( name, value, length ); 40002860: 90 10 00 18 mov %i0, %o0 { 40002864: ba 10 00 18 mov %i0, %i5 p = rtems_bsp_cmdline_get_param( name, value, length ); 40002868: 94 10 00 1a mov %i2, %o2 4000286c: 7f ff ff b8 call 4000274c 40002870: 92 10 00 19 mov %i1, %o1 if ( !p ) 40002874: b0 92 20 00 orcc %o0, 0, %i0 40002878: 02 80 00 23 be 40002904 4000287c: 01 00 00 00 nop return NULL; rhs = &p[strlen(name)]; 40002880: 40 00 2d 47 call 4000dd9c 40002884: 90 10 00 1d mov %i5, %o0 if ( *rhs != '=' ) 40002888: c2 4e 00 08 ldsb [ %i0 + %o0 ], %g1 4000288c: 80 a0 60 3d cmp %g1, 0x3d 40002890: 12 80 00 1c bne 40002900 40002894: b0 06 00 08 add %i0, %o0, %i0 return NULL; rhs++; if ( *rhs == '\"' ) 40002898: c4 0e 20 01 ldub [ %i0 + 1 ], %g2 4000289c: 83 28 a0 18 sll %g2, 0x18, %g1 400028a0: 87 38 60 18 sra %g1, 0x18, %g3 400028a4: 80 a0 e0 22 cmp %g3, 0x22 400028a8: 02 80 00 19 be 4000290c 400028ac: 80 a0 60 00 cmp %g1, 0 rhs++; for ( d=value ; *rhs ; ) 400028b0: 02 80 00 1c be 40002920 400028b4: b0 06 20 01 inc %i0 400028b8: 10 80 00 03 b 400028c4 400028bc: 82 10 00 19 mov %i1, %g1 400028c0: 84 10 00 04 mov %g4, %g2 *d++ = *rhs++; 400028c4: c4 28 40 00 stb %g2, [ %g1 ] 400028c8: b0 06 20 01 inc %i0 for ( d=value ; *rhs ; ) 400028cc: c6 4e 00 00 ldsb [ %i0 ], %g3 *d++ = *rhs++; 400028d0: 82 00 60 01 inc %g1 for ( d=value ; *rhs ; ) 400028d4: 80 a0 e0 00 cmp %g3, 0 400028d8: 12 bf ff fa bne 400028c0 400028dc: c8 0e 00 00 ldub [ %i0 ], %g4 if ( *(d-1) == '\"' ) 400028e0: 85 28 a0 18 sll %g2, 0x18, %g2 400028e4: 85 38 a0 18 sra %g2, 0x18, %g2 d--; 400028e8: 84 18 a0 22 xor %g2, 0x22, %g2 400028ec: 80 a0 00 02 cmp %g0, %g2 400028f0: 82 40 7f ff addx %g1, -1, %g1 *d = '\0'; 400028f4: c0 28 40 00 clrb [ %g1 ] return value; 400028f8: 81 c7 e0 08 ret 400028fc: 91 e8 00 19 restore %g0, %i1, %o0 return NULL; 40002900: b0 10 20 00 clr %i0 } 40002904: 81 c7 e0 08 ret 40002908: 81 e8 00 00 restore 4000290c: c4 0e 20 02 ldub [ %i0 + 2 ], %g2 40002910: 83 28 a0 18 sll %g2, 0x18, %g1 for ( d=value ; *rhs ; ) 40002914: 80 a0 60 00 cmp %g1, 0 40002918: 12 bf ff e8 bne 400028b8 <== ALWAYS TAKEN 4000291c: b0 06 20 02 add %i0, 2, %i0 40002920: c4 0e 7f ff ldub [ %i1 + -1 ], %g2 40002924: 82 10 00 19 mov %i1, %g1 if ( *(d-1) == '\"' ) 40002928: 85 28 a0 18 sll %g2, 0x18, %g2 4000292c: 85 38 a0 18 sra %g2, 0x18, %g2 d--; 40002930: 84 18 a0 22 xor %g2, 0x22, %g2 40002934: 80 a0 00 02 cmp %g0, %g2 40002938: 82 40 7f ff addx %g1, -1, %g1 *d = '\0'; 4000293c: c0 28 40 00 clrb [ %g1 ] return value; 40002940: 81 c7 e0 08 ret 40002944: 91 e8 00 19 restore %g0, %i1, %o0