[*] Binary protection state of ubiattach

  
  	Partial RELRO  No Canary found   NX disabled  No PIE       No RPATH     No RUNPATH   No Symbols


[*] Function fprintf tear down of ubiattach

    ; assembly                                           | /* r2dec pseudo code output */
                                                         | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x1123c */
                                                         | #include <stdint.h>
                                                         |  
    ; (fcn) fcn.0001123c ()                              | void fcn_0001123c (int32_t arg1, int32_t arg2) {
                                                         |     int32_t var_0h;
                                                         |     char * * endptr;
                                                         |     int32_t var_10h;
                                                         |     r0 = arg1;
                                                         |     r1 = arg2;
    0x0001123c push {r0, r1, r2, r3, r4, r5, r6, lr}     |     
    0x00011240 mov r6, r1                                |     r6 = r1;
    0x00011244 mov r2, 0                                 |     r2 = 0;
    0x00011248 add r1, sp, 0xc                           |     r1 += endptr;
    0x0001124c mov r4, r0                                |     r4 = r0;
    0x00011250 bl 0x10a34                                |     strtoul (r0, r1, r2);
    0x00011254 ldrb r3, [r4]                             |     r3 = *(r4);
    0x00011258 cmp r3, 0                                 |     
    0x0001125c mov r5, r0                                |     r5 = r0;
                                                         |     if (r3 != 0) {
    0x00011260 beq 0x11274                               |         
    0x00011264 ldr r3, [sp, 0xc]                         |         r3 = endptr;
    0x00011268 ldrb r3, [r3]                             |         r3 = *(r3);
    0x0001126c cmp r3, 0                                 |         
                                                         |         if (r3 == 0) {
    0x00011270 beq 0x11298                               |             goto label_0;
                                                         |         }
                                                         |     }
    0x00011274 ldr r0, [pc, 0x28]                        |     
    0x00011278 str r4, [sp]                              |     *(sp) = r4;
    0x0001127c ldr r3, [pc, 0x24]                        |     r3 = stderr;
    0x00011280 ldr r2, [pc, 0x24]                        |     r2 = "strtoul";
    0x00011284 ldr r1, [pc, 0x24]                        |     r1 = "ubiattach";
    0x00011288 ldr r0, [r0]                              |     r0 = *(0x112a0);
    0x0001128c bl 0x10a64                                |     fprintf (r0, "ubiattach", "strtoul", r3, r4)
    0x00011290 mov r3, 1                                 |     r3 = 1;
    0x00011294 str r3, [r6]                              |     *(r6) = r3;
                                                         | label_0:
    0x00011298 mov r0, r5                                |     r0 = r5;
    0x0001129c add sp, sp, 0x10                          |     
    0x000112a0 pop {r4, r5, r6, pc}                      |     
                                                         | }
    ; assembly                               | /* r2dec pseudo code output */
                                             | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x1157c */
                                             | #include <stdint.h>
                                             |  
    ; (fcn) fcn.0001157c ()                  | void fcn_0001157c (int32_t arg1, int32_t arg2) {
                                             |     int32_t var_0h;
                                             |     int32_t var_4h;
                                             |     int32_t var_8h;
                                             |     char * buf;
                                             |     char * s;
                                             |     int32_t var_4ch;
                                             |     r0 = arg1;
                                             |     r1 = arg2;
    0x0001157c push {r4, r5, r6, r7, lr}     |     
    0x00011580 mov r6, r1                    |     r6 = r1;
    0x00011584 sub sp, sp, 0x4c              |     
    0x00011588 mov r1, 0                     |     r1 = 0;
    0x0001158c mov r5, r0                    |     r5 = r0;
    0x00011590 bl 0x10af4                    |     r0 = open64 ();
    0x00011594 cmn r0, 1                     |     
    0x00011598 mov r4, r0                    |     r4 = r0;
                                             |     if (r0 == 1) {
    0x0001159c beq 0x116f8                   |         goto label_2;
                                             |     }
    0x000115a0 mov r2, 0x32                  |     r2 = 0x32;
    0x000115a4 add r1, sp, 0x14              |     r1 += buf;
    0x000115a8 bl 0x10a7c                    |     r0 = read (r0, r1, r2);
    0x000115ac cmn r0, 1                     |     
                                             |     if (r0 != 1) {
    0x000115b0 bne 0x11608                   |         goto label_3;
                                             |     }
    0x000115b4 bl 0x10b24                    |     errno_location ();
    0x000115b8 ldr r7, [pc, 0x144]           |     r7 = *(0x11700);
    0x000115bc mov r3, r5                    |     r3 = r5;
    0x000115c0 ldr r2, [pc, 0x140]           |     r2 = stderr;
    0x000115c4 ldr r1, [pc, 0x140]           |     r1 = "libubi";
    0x000115c8 ldr r6, [r0]                  |     r6 = *(r0);
    0x000115cc ldr r0, [r7]                  |     r0 = *(0x11700);
    0x000115d0 bl 0x10a64                    |     fprintf (r0, "libubi", r2, r3, r4, r5, r6)
    0x000115d4 mov r0, r6                    |     r0 = r6;
    0x000115d8 ldr r5, [r7]                  |     r5 = *(0x11700);
    0x000115dc bl 0x109d4                    |     strerror (r0);
    0x000115e0 str r6, [sp]                  |     *(sp) = r6;
    0x000115e4 ldr r3, [pc, 0x124]           |     r3 = "%s: error!: cannot read \"%s\"\n";
    0x000115e8 mov r2, 8                     |     r2 = 8;
    0x000115ec ldr r1, [pc, 0x120]           |     r1 = *(0x11710);
    0x000115f0 str r0, [sp, 4]               |     var_4h = r0;
    0x000115f4 mov r0, r5                    |     r0 = r5;
    0x000115f8 bl 0x10a64                    |     fprintf (r0, r1, r2, "%s: error!: cannot read \"%s\"\n", r4, r5, r6)
                                             |     do {
    0x000115fc mov r0, r4                    |         r0 = r4;
    0x00011600 bl 0x10b6c                    |         close (r0);
    0x00011604 b 0x116f4                     |         goto label_4;
                                             | label_3:
    0x00011608 cmp r0, 0x32                  |         
                                             |         if (r0 != 0x32) {
    0x0001160c bne 0x11638                   |             goto label_5;
                                             |         }
    0x00011610 ldr r2, [pc, 0xf0]            |         r2 = stderr;
    0x00011614 ldr r1, [pc, 0xfc]            |         r1 = "_serror__d___s_";
    0x00011618 mov r3, r5                    |         r3 = r5;
                                             | label_0:
    0x0001161c ldr r0, [pc, 0xe0]            |         
    0x00011620 ldr r0, [r0]                  |         r0 = *(0x11700);
    0x00011624 bl 0x10a64                    |         r0 = fprintf (r0, "_serror__d___s_", r2, r3)
                                             | label_1:
    0x00011628 bl 0x10b24                    |         errno_location ();
    0x0001162c mov r3, 0x16                  |         r3 = 0x16;
    0x00011630 str r3, [r0]                  |         *(r0) = r3;
    0x00011634 b 0x115fc                     |         
                                             |     } while (1);
                                             | label_5:
    0x00011638 add r3, sp, 0x48              |     r3 += s;
    0x0001163c add r0, r3, r0                |     r0 = r3 + r0;
    0x00011640 mov r3, 0                     |     r3 = 0;
    0x00011644 strb r3, [r0, -0x34]          |     buf = r3;
    0x00011648 mov r2, r6                    |     r2 = r6;
    0x0001164c ldr r1, [pc, 0xc8]            |     r1 = "%s: error!: contents of \"%s\" is too long\n";
    0x00011650 add r0, sp, 0x14              |     r0 += buf;
    0x00011654 bl 0x10aac                    |     r0 = sscanf (r0, "%s: error!: contents of \"%s\" is too long\n", r2);
    0x00011658 cmp r0, 1                     |     
                                             |     if (r0 == 1) {
    0x0001165c movne r3, r5                  |         r3 = r5;
                                             |     }
                                             |     if (r0 == 1) {
    0x00011660 ldrne r2, [pc, 0xa0]          |         r2 = "libubi";
                                             |     }
                                             |     if (r0 != 1) {
    0x00011664 ldrne r1, [pc, 0xb4]          |         r1 = "%s: error!: cannot read integer from \"%s\"\n\n";
                                             |         goto label_6;
                                             |     }
                                             |     if (r0 != 1) {
                                             | label_6:
    0x00011668 bne 0x1161c                   |         goto label_0;
                                             |     }
    0x0001166c ldrd r2, r3, [r6]             |     __asm ("ldrd r2, r3, [r6]");
    0x00011670 cmp r2, 0                     |     
    0x00011674 sbcs r1, r3, 0                |     __asm ("sbcs r1, r3, 0");
                                             |     if (r2 < 0) {
    0x00011678 bge 0x1169c                   |         
    0x0001167c strd r2, r3, [sp]             |         __asm ("strd r2, r3, [sp]");
    0x00011680 ldr r3, [pc, 0x7c]            |         r3 = *(0x11700);
    0x00011684 str r5, [sp, 8]               |         var_8h = r5;
    0x00011688 ldr r2, [pc, 0x78]            |         r2 = stderr;
    0x0001168c ldr r1, [pc, 0x90]            |         r1 = "%s: error!: cannot read integer from \"%s\"\n\n";
    0x00011690 ldr r0, [r3]                  |         r0 = *(0x11700);
    0x00011694 bl 0x10a64                    |         fprintf (r0, "%s: error!: cannot read integer from \"%s\"\n\n", r2, r3, r4, r5)
    0x00011698 b 0x11628                     |         goto label_1;
                                             |     }
    0x0001169c mov r0, r4                    |     r0 = r4;
    0x000116a0 bl 0x10b6c                    |     r0 = close (r0);
    0x000116a4 subs r4, r0, 0                |     r4 = r0 - 0;
                                             |     if (r4 != r0) {
    0x000116a8 beq 0x116f8                   |         
    0x000116ac bl 0x10b24                    |         errno_location ();
    0x000116b0 ldr r6, [pc, 0x4c]            |         r6 = *(0x11700);
    0x000116b4 mov r3, r5                    |         r3 = r5;
    0x000116b8 ldr r2, [pc, 0x48]            |         r2 = stderr;
    0x000116bc ldr r1, [pc, 0x64]            |         r1 = "%s: error!: negative value %lld in \"%s\"\n";
    0x000116c0 ldr r4, [r0]                  |         r4 = *(r0);
    0x000116c4 ldr r0, [r6]                  |         r0 = *(0x11700);
    0x000116c8 bl 0x10a64                    |         fprintf (r0, "%s: error!: negative value %lld in \"%s\"\n", r2, r3, r4, r5, r6)
    0x000116cc mov r0, r4                    |         r0 = r4;
    0x000116d0 ldr r5, [r6]                  |         r5 = *(0x11700);
    0x000116d4 bl 0x109d4                    |         strerror (r0);
    0x000116d8 str r4, [sp]                  |         *(sp) = r4;
    0x000116dc ldr r3, [pc, 0x2c]            |         r3 = "%s: error!: cannot read \"%s\"\n";
    0x000116e0 mov r2, 8                     |         r2 = 8;
    0x000116e4 ldr r1, [pc, 0x28]            |         r1 = *(0x11710);
    0x000116e8 str r0, [sp, 4]               |         var_4h = r0;
    0x000116ec mov r0, r5                    |         r0 = r5;
    0x000116f0 bl 0x10a64                    |         fprintf (r0, r1, r2, "%s: error!: cannot read \"%s\"\n", r4)
                                             | label_4:
    0x000116f4 mvn r4, 0                     |         r4 = ~0;
                                             |     }
                                             | label_2:
    0x000116f8 mov r0, r4                    |     r0 = r4;
    0x000116fc add sp, sp, 0x4c              |     
    0x00011700 pop {r4, r5, r6, r7, pc}      |     
                                             | }
    ; assembly                               | /* r2dec pseudo code output */
                                             | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x1172c */
                                             | #include <stdint.h>
                                             |  
    ; (fcn) fcn.0001172c ()                  | void fcn_0001172c (int32_t arg1, int32_t arg2) {
                                             |     int32_t var_0h;
                                             |     int32_t var_0h_2;
                                             |     int32_t var_8h;
                                             |     int32_t var_10h;
                                             |     int32_t var_10h_2;
                                             |     int32_t var_1ch;
                                             |     r0 = arg1;
                                             |     r1 = arg2;
    0x0001172c push {r4, r5, lr}             |     
    0x00011730 sub sp, sp, 0x1c              |     
    0x00011734 mov r4, r1                    |     r4 = r1;
    0x00011738 add r1, sp, 0x10              |     r1 += var_10h;
    0x0001173c mov r5, r0                    |     r5 = r0;
    0x00011740 bl 0x1157c                    |     r0 = fcn_0001157c (r0, r1);
    0x00011744 cmp r0, 0                     |     
                                             |     if (r0 == 0) {
    0x00011748 bne 0x11788                   |         
    0x0001174c ldrd r2, r3, [sp, 0x10]       |         __asm ("ldrd r2, r3, [var_10h]");
    0x00011750 cmp r2, 0x80000000            |         
    0x00011754 sbcs r1, r3, 0                |         __asm ("sbcs r1, r3, 0");
                                             |         if (r2 >= 0x80000000) {
    0x00011758 strlt r2, [r4]                |             *(r4) = r2;
                                             |         }
                                             |         if (r2 < 0x80000000) {
    0x0001175c blt 0x1178c                   |             goto label_0;
                                             |         }
    0x00011760 strd r2, r3, [sp]             |         __asm ("strd r2, r3, [sp]");
    0x00011764 ldr r3, [pc, 0x28]            |         r3 = *(0x11790);
    0x00011768 str r5, [sp, 8]               |         var_8h = r5;
    0x0001176c ldr r2, [pc, 0x24]            |         r2 = stderr;
    0x00011770 ldr r0, [r3]                  |         r0 = *(0x11790);
    0x00011774 ldr r1, [pc, 0x20]            |         r1 = "libubi";
    0x00011778 bl 0x10a64                    |         r0 = fprintf (r0, "libubi", r2, r3, r4, r5)
    0x0001177c bl 0x10b24                    |         errno_location ();
    0x00011780 mov r3, 0x16                  |         r3 = 0x16;
    0x00011784 str r3, [r0]                  |         *(r0) = r3;
                                             |     }
    0x00011788 mvn r0, 0                     |     r0 = ~0;
                                             | label_0:
    0x0001178c add sp, sp, 0x1c              |     
    0x00011790 pop {r4, r5, pc}              |     
                                             | }
    ; assembly                                                   | /* r2dec pseudo code output */
                                                                 | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x11838 */
                                                                 | #include <stdint.h>
                                                                 |  
    ; (fcn) fcn.00011838 ()                                      | void fcn_00011838 (int32_t arg1, int32_t arg2) {
                                                                 |     int32_t var_0h;
                                                                 |     int32_t var_4h;
                                                                 |     void * buf;
                                                                 |     int32_t var_10h;
                                                                 |     r0 = arg1;
                                                                 |     r1 = arg2;
    0x00011838 push {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr}     |     
    0x0001183c mov r8, r1                                        |     r8 = r1;
    0x00011840 mov r1, 0                                         |     r1 = 0;
    0x00011844 mov r5, r0                                        |     r5 = r0;
    0x00011848 mov r7, r2                                        |     r7 = r2;
    0x0001184c bl 0x10af4                                        |     r0 = open64 ();
    0x00011850 cmn r0, 1                                         |     
    0x00011854 mov r4, r0                                        |     r4 = r0;
                                                                 |     if (r0 == 1) {
    0x00011858 beq 0x119a0                                       |         goto label_2;
                                                                 |     }
    0x0001185c mov r2, r7                                        |     r2 = r7;
    0x00011860 mov r1, r8                                        |     r1 = r8;
    0x00011864 bl 0x10a7c                                        |     r0 = read (r0, r1, r2);
    0x00011868 cmn r0, 1                                         |     
    0x0001186c mov r6, r0                                        |     r6 = r0;
                                                                 |     if (r0 != 1) {
    0x00011870 bne 0x118c8                                       |         goto label_3;
                                                                 |     }
                                                                 | label_0:
    0x00011874 bl 0x10b24                                        |     errno_location ();
    0x00011878 ldr r7, [pc, 0x12c]                               |     r7 = *(0x119a8);
    0x0001187c mov r3, r5                                        |     r3 = r5;
    0x00011880 ldr r2, [pc, 0x128]                               |     r2 = stderr;
    0x00011884 ldr r1, [pc, 0x128]                               |     r1 = "libubi";
    0x00011888 ldr r6, [r0]                                      |     r6 = *(r0);
    0x0001188c ldr r0, [r7]                                      |     r0 = *(0x119a8);
    0x00011890 bl 0x10a64                                        |     fprintf (r0, "libubi", r2, r3, r4, r5, r6)
    0x00011894 mov r0, r6                                        |     r0 = r6;
    0x00011898 ldr r5, [r7]                                      |     r5 = *(0x119a8);
    0x0001189c bl 0x109d4                                        |     strerror (r0);
    0x000118a0 str r6, [sp]                                      |     *(sp) = r6;
    0x000118a4 ldr r3, [pc, 0x10c]                               |     r3 = "%s: error!: cannot read \"%s\"\n";
    0x000118a8 mov r2, 8                                         |     r2 = 8;
    0x000118ac ldr r1, [pc, 0x108]                               |     r1 = *(0x119b8);
    0x000118b0 str r0, [sp, 4]                                   |     var_4h = r0;
    0x000118b4 mov r0, r5                                        |     r0 = r5;
    0x000118b8 bl 0x10a64                                        |     fprintf (r0, r1, r2, "%s: error!: cannot read \"%s\"\n", r4, r5, r6)
                                                                 |     do {
    0x000118bc mov r0, r4                                        |         r0 = r4;
    0x000118c0 bl 0x10b6c                                        |         close (r0);
    0x000118c4 b 0x1199c                                         |         goto label_4;
                                                                 | label_3:
    0x000118c8 cmp r7, r0                                        |         
                                                                 |         if (r7 != r0) {
    0x000118cc bne 0x118f8                                       |             goto label_5;
                                                                 |         }
    0x000118d0 ldr r0, [pc, 0xd4]                                |         
    0x000118d4 mov r3, r5                                        |         r3 = r5;
    0x000118d8 ldr r2, [pc, 0xd0]                                |         r2 = stderr;
    0x000118dc ldr r1, [pc, 0xdc]                                |         r1 = "_serror__d___s_";
    0x000118e0 ldr r0, [r0]                                      |         r0 = *(0x119a8);
    0x000118e4 bl 0x10a64                                        |         r0 = fprintf (r0, "_serror__d___s_", r2, r3)
                                                                 | label_1:
    0x000118e8 bl 0x10b24                                        |         errno_location ();
    0x000118ec mov r3, 0x16                                      |         r3 = 0x16;
    0x000118f0 str r3, [r0]                                      |         *(r0) = r3;
    0x000118f4 b 0x118bc                                         |         
                                                                 |     } while (1);
                                                                 | label_5:
    0x000118f8 mov r3, 0                                         |     r3 = 0;
    0x000118fc strb r3, [r8, r0]                                 |     *((r8 + r0)) = r3;
    0x00011900 mov r2, 1                                         |     r2 = 1;
    0x00011904 add r1, sp, 0xc                                   |     r1 += buf;
    0x00011908 mov r0, r4                                        |     r0 = r4;
    0x0001190c bl 0x10a7c                                        |     r0 = read (r0, r1, r2);
    0x00011910 cmp r0, 1                                         |     
                                                                 |     if (r0 == 1) {
    0x00011914 beq 0x11874                                       |         goto label_0;
                                                                 |     }
    0x00011918 cmp r0, 0                                         |     
                                                                 |     if (r0 != 0) {
    0x0001191c beq 0x11940                                       |         
    0x00011920 ldr r0, [pc, 0x84]                                |         
    0x00011924 str r7, [sp]                                      |         *(sp) = r7;
    0x00011928 mov r3, r5                                        |         r3 = r5;
    0x0001192c ldr r2, [pc, 0x7c]                                |         r2 = stderr;
    0x00011930 ldr r1, [pc, 0x8c]                                |         r1 = "%s: error!: contents of \"%s\" is too long\n";
    0x00011934 ldr r0, [r0]                                      |         r0 = *(0x119a8);
    0x00011938 bl 0x10a64                                        |         fprintf (r0, "%s: error!: contents of \"%s\" is too long\n", r2, r3)
    0x0001193c b 0x118e8                                         |         goto label_1;
                                                                 |     }
    0x00011940 mov r0, r4                                        |     r0 = r4;
    0x00011944 bl 0x10b6c                                        |     r0 = close (r0);
    0x00011948 cmp r0, 0                                         |     
                                                                 |     if (r0 != 0) {
    0x0001194c moveq r4, r6                                      |         r4 = r6;
                                                                 |     }
                                                                 |     if (r0 != 0) {
    0x00011950 beq 0x119a0                                       |         
    0x00011954 bl 0x10b24                                        |         errno_location ();
    0x00011958 ldr r6, [pc, 0x4c]                                |         r6 = *(0x119a8);
    0x0001195c mov r3, r5                                        |         r3 = r5;
    0x00011960 ldr r2, [pc, 0x48]                                |         r2 = stderr;
    0x00011964 ldr r1, [pc, 0x5c]                                |         r1 = "_s:_error_:_file___s__contains_too_much_data_____d_bytes_";
    0x00011968 ldr r4, [r0]                                      |         r4 = *(r0);
    0x0001196c ldr r0, [r6]                                      |         r0 = *(0x119a8);
    0x00011970 bl 0x10a64                                        |         fprintf (r0, "_s:_error_:_file___s__contains_too_much_data_____d_bytes_", r2, r3, r4, r5, r6)
    0x00011974 mov r0, r4                                        |         r0 = r4;
    0x00011978 ldr r5, [r6]                                      |         r5 = *(0x119a8);
    0x0001197c bl 0x109d4                                        |         strerror (r0);
    0x00011980 str r4, [sp]                                      |         *(sp) = r4;
    0x00011984 ldr r3, [pc, 0x2c]                                |         r3 = "%s: error!: cannot read \"%s\"\n";
    0x00011988 mov r2, 8                                         |         r2 = 8;
    0x0001198c ldr r1, [pc, 0x28]                                |         r1 = *(0x119b8);
    0x00011990 str r0, [sp, 4]                                   |         var_4h = r0;
    0x00011994 mov r0, r5                                        |         r0 = r5;
    0x00011998 bl 0x10a64                                        |         fprintf (r0, r1, r2, "%s: error!: cannot read \"%s\"\n", r4)
                                                                 | label_4:
    0x0001199c mvn r4, 0                                         |         r4 = ~0;
                                                                 |     }
                                                                 | label_2:
    0x000119a0 mov r0, r4                                        |     r0 = r4;
    0x000119a4 add sp, sp, 0x10                                  |     
    0x000119a8 pop {r4, r5, r6, r7, r8, pc}                      |     
                                                                 | }
    ; assembly                                                   | /* r2dec pseudo code output */
                                                                 | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x119cc */
                                                                 | #include <stdint.h>
                                                                 |  
    ; (fcn) fcn.000119cc ()                                      | void fcn_000119cc (int32_t arg1, int32_t arg2) {
                                                                 |     int32_t var_0h;
                                                                 |     int32_t var_4h;
                                                                 |     int32_t var_8h;
                                                                 |     r0 = arg1;
                                                                 |     r1 = arg2;
    0x000119cc push {r0, r1, r4, r5, r6, r7, r8, sb, sl, lr}     |     
    0x000119d0 mov r7, r1                                        |     r7 = r1;
    0x000119d4 mov sl, r0                                        |     sl = r0;
    0x000119d8 bl 0x10b3c                                        |     r0 = strlen (r0);
    0x000119dc mov r4, r0                                        |     r4 = r0;
    0x000119e0 mov sb, r0                                        |     sb = r0;
    0x000119e4 mov r0, r7                                        |     r0 = r7;
    0x000119e8 bl 0x10b3c                                        |     r0 = strlen (r0);
    0x000119ec add r6, r4, r0                                    |     r6 = r4 + r0;
    0x000119f0 add r6, r6, 2                                     |     r6 += 2;
    0x000119f4 mov r8, r0                                        |     r8 = r0;
    0x000119f8 mov r0, r6                                        |     r0 = r6;
    0x000119fc bl 0x10a28                                        |     r0 = malloc (r0);
    0x00011a00 subs r5, r0, 0                                    |     r5 = r0 - 0;
                                                                 |     if (r5 != r0) {
    0x00011a04 bne 0x11a5c                                       |         goto label_0;
                                                                 |     }
    0x00011a08 bl 0x10b24                                        |     errno_location ();
    0x00011a0c ldr r7, [pc, 0x80]                                |     r7 = *(0x11a90);
    0x00011a10 mov r3, r6                                        |     r3 = r6;
    0x00011a14 ldr r2, [pc, 0x7c]                                |     r2 = stderr;
    0x00011a18 ldr r1, [pc, 0x7c]                                |     r1 = "libubi";
    0x00011a1c ldr r4, [r0]                                      |     r4 = *(r0);
    0x00011a20 ldr r0, [r7]                                      |     r0 = *(0x11a90);
    0x00011a24 bl 0x10a64                                        |     fprintf (r0, "libubi", r2, r3, r4)
    0x00011a28 mov r0, r4                                        |     r0 = r4;
    0x00011a2c ldr r6, [r7]                                      |     r6 = *(0x11a90);
    0x00011a30 bl 0x109d4                                        |     strerror (r0);
    0x00011a34 str r4, [sp]                                      |     *(sp) = r4;
    0x00011a38 ldr r3, [pc, 0x60]                                |     r3 = "%s: error!: cannot allocate %d bytes\n";
    0x00011a3c mov r2, 8                                         |     r2 = 8;
    0x00011a40 ldr r1, [pc, 0x5c]                                |     r1 = *(0x11aa0);
    0x00011a44 str r0, [sp, 4]                                   |     var_4h = r0;
    0x00011a48 mov r0, r6                                        |     r0 = r6;
    0x00011a4c bl 0x10a64                                        |     fprintf (r0, r1, r2, "%s: error!: cannot allocate %d bytes\n", r4)
                                                                 |     do {
    0x00011a50 mov r0, r5                                        |         r0 = r5;
    0x00011a54 add sp, sp, 8                                     |         
    0x00011a58 pop {r4, r5, r6, r7, r8, sb, sl, pc}              |         
                                                                 | label_0:
    0x00011a5c mov r2, r4                                        |         r2 = r4;
    0x00011a60 mov r1, sl                                        |         r1 = sl;
    0x00011a64 bl 0x10a10                                        |         memcpy (r0, r1, r2);
    0x00011a68 add r3, r5, r4                                    |         r3 = r5 + r4;
    0x00011a6c ldrb r3, [r3, -1]                                 |         r3 = *((r3 - 1));
    0x00011a70 add r2, r8, 1                                     |         r2 = r8 + 1;
    0x00011a74 cmp r3, 0x2f                                      |         
                                                                 |         if (r3 == 0x2f) {
    0x00011a78 addne r4, r4, 1                                   |             r4++;
                                                                 |         }
                                                                 |         if (r3 == 0x2f) {
    0x00011a7c movne r3, 0x2f                                    |             r3 = 0x2f;
                                                                 |         }
                                                                 |         if (r3 == 0x2f) {
    0x00011a80 strbne r3, [r5, sb]                               |             *((r5 + sb)) = r3;
                                                                 |         }
    0x00011a84 mov r1, r7                                        |         r1 = r7;
    0x00011a88 add r0, r5, r4                                    |         r0 = r5 + r4;
    0x00011a8c bl 0x10a10                                        |         memcpy (r0, r1, r2);
    0x00011a90 b 0x11a50                                         |         
                                                                 |     } while (1);
                                                                 | }
    ; assembly                                   | /* r2dec pseudo code output */
                                                 | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x11aa8 */
                                                 | #include <stdint.h>
                                                 |  
    ; (fcn) fcn.00011aa8 ()                      | void fcn_00011aa8 (int32_t arg1) {
                                                 |     int32_t var_0h;
                                                 |     int32_t var_4h;
                                                 |     int32_t var_8h;
                                                 |     int32_t var_18h;
                                                 |     int32_t var_28h;
                                                 |     int32_t var_28h_2;
                                                 |     int32_t var_74h;
                                                 |     r0 = arg1;
    0x00011aa8 push {r4, r5, r6, r7, lr}         |     
    0x00011aac sub sp, sp, 0x74                  |     
    0x00011ab0 add r1, sp, 8                     |     r1 += var_8h;
    0x00011ab4 mov r5, r0                        |     r5 = r0;
    0x00011ab8 bl 0x109e0                        |     r0 = stat64 ();
    0x00011abc cmp r0, 0                         |     
                                                 |     if (r0 >= 0) {
    0x00011ac0 bge 0x11b18                       |         goto label_2;
                                                 |     }
    0x00011ac4 bl 0x10b24                        |     errno_location ();
    0x00011ac8 ldr r6, [pc, 0xc8]                |     r6 = *(0x11b94);
    0x00011acc ldr r2, [pc, 0xc8]                |     r2 = stderr;
    0x00011ad0 ldr r1, [pc, 0xc8]                |     r1 = "libubi";
    0x00011ad4 mov r3, r5                        |     r3 = r5;
    0x00011ad8 ldr r4, [r0]                      |     r4 = *(r0);
                                                 |     do {
                                                 | label_1:
    0x00011adc ldr r0, [r6]                      |         r0 = *(r6);
    0x00011ae0 bl 0x10a64                        |         fprintf (r0, "libubi", r2, r3, r4, r5, r6)
    0x00011ae4 mov r0, r4                        |         r0 = r4;
    0x00011ae8 ldr r5, [r6]                      |         r5 = *(r6);
    0x00011aec bl 0x109d4                        |         strerror (r0);
    0x00011af0 str r4, [sp]                      |         *(sp) = r4;
    0x00011af4 ldr r3, [pc, 0xa8]                |         r3 = "%s: error!: cannot stat \"%s\"\n";
    0x00011af8 mov r2, 8                         |         r2 = 8;
    0x00011afc ldr r1, [pc, 0xa4]                |         r1 = *(0x11ba4);
    0x00011b00 str r0, [sp, 4]                   |         var_4h = r0;
    0x00011b04 mov r0, r5                        |         r0 = r5;
    0x00011b08 bl 0x10a64                        |         fprintf (r0, r1, r2, "%s: error!: cannot stat \"%s\"\n", r4)
    0x00011b0c mvn r0, 0                         |         r0 = ~0;
                                                 | label_0:
    0x00011b10 add sp, sp, 0x74                  |         
    0x00011b14 pop {r4, r5, r6, r7, pc}          |         
                                                 | label_2:
    0x00011b18 ldr r3, [sp, 0x18]                |         r3 = var_18h;
    0x00011b1c and r3, r3, 0xf000                |         r3 &= 0xf000;
    0x00011b20 cmp r3, 0x2000                    |         
                                                 |         if (r3 == 0x2000) {
    0x00011b24 beq 0x11b48                       |             goto label_3;
                                                 |         }
    0x00011b28 bl 0x10b24                        |         errno_location ();
    0x00011b2c mov r4, 0x16                      |         r4 = 0x16;
    0x00011b30 ldr r6, [pc, 0x60]                |         r6 = *(0x11b94);
    0x00011b34 mov r3, r5                        |         r3 = r5;
    0x00011b38 ldr r2, [pc, 0x5c]                |         r2 = stderr;
    0x00011b3c ldr r1, [pc, 0x68]                |         r1 = "_serror__d___s_";
    0x00011b40 str r4, [r0]                      |         *(r0) = r4;
    0x00011b44 b 0x11adc                         |         
                                                 |     } while (1);
                                                 | label_3:
    0x00011b48 ldrd r6, r7, [sp, 0x28]           |     __asm ("ldrd r6, r7, [var_28h]");
    0x00011b4c mov r1, r7                        |     r1 = r7;
    0x00011b50 mov r0, r6                        |     r0 = r6;
    0x00011b54 bl 0x10a04                        |     gnu_dev_major ();
    0x00011b58 mov r1, r7                        |     r1 = r7;
    0x00011b5c mov r4, r0                        |     r4 = r0;
    0x00011b60 mov r0, r6                        |     r0 = r6;
    0x00011b64 bl 0x10a40                        |     gnu_dev_minor ();
    0x00011b68 cmp r4, 0x5a                      |     
                                                 |     if (r4 != 0x5a) {
    0x00011b6c addeq r0, r0, r0, lsr 31          |         r0 += (r0 >> 31);
                                                 |     }
    0x00011b70 asreq r0, r0, 1                   |     __asm ("asreq r0, r0, 1");
                                                 |     if (r4 == 0x5a) {
    0x00011b74 beq 0x11b10                       |         goto label_0;
                                                 |     }
    0x00011b78 bl 0x10b24                        |     errno_location ();
    0x00011b7c mov r4, 0x16                      |     r4 = 0x16;
    0x00011b80 ldr r6, [pc, 0x10]                |     r6 = *(0x11b94);
    0x00011b84 mov r3, r5                        |     r3 = r5;
    0x00011b88 ldr r2, [pc, 0xc]                 |     r2 = stderr;
    0x00011b8c ldr r1, [pc, 0x1c]                |     r1 = "%s: error!: \"%s\" is not a character device\n";
    0x00011b90 str r4, [r0]                      |     *(r0) = r4;
    0x00011b94 b 0x11adc                         |     goto label_1;
                                                 | }
    ; assembly                               | /* r2dec pseudo code output */
                                             | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x11bb4 */
                                             | #include <stdint.h>
                                             |  
    ; (fcn) fcn.00011bb4 ()                  | void fcn_00011bb4 (int32_t arg1, int32_t arg2) {
                                             |     int32_t var_0h;
                                             |     int32_t var_4h;
                                             |     char * s;
                                             |     int32_t var_40h;
                                             |     r0 = arg1;
                                             |     r1 = arg2;
    0x00011bb4 push {r4, r5, r6, lr}         |     
    0x00011bb8 sub sp, sp, 0x40              |     
    0x00011bbc mov r4, r1                    |     r4 = r1;
    0x00011bc0 mov r5, r2                    |     r5 = r2;
    0x00011bc4 add r1, sp, 0xc               |     r1 += s;
    0x00011bc8 mov r2, 0x32                  |     r2 = 0x32;
    0x00011bcc mov r6, r0                    |     r6 = r0;
    0x00011bd0 bl 0x11838                    |     r0 = fcn_00011838 (r0, r1);
    0x00011bd4 cmp r0, 0                     |     
                                             |     if (r0 < 0) {
    0x00011bd8 blt 0x11c20                   |         goto label_1;
                                             |     }
    0x00011bdc mov r3, r5                    |     r3 = r5;
    0x00011be0 mov r2, r4                    |     r2 = r4;
    0x00011be4 ldr r1, [pc, 0x8c]            |     r1 = *(0x11c74);
    0x00011be8 add r0, sp, 0xc               |     r0 += s;
    0x00011bec bl 0x10aac                    |     r0 = sscanf (r0, r1, r2);
    0x00011bf0 cmp r0, 2                     |     
                                             |     if (r0 == 2) {
    0x00011bf4 beq 0x11c28                   |         goto label_2;
                                             |     }
    0x00011bf8 bl 0x10b24                    |     errno_location ();
    0x00011bfc mov r3, 0x16                  |     r3 = 0x16;
    0x00011c00 ldr r2, [pc, 0x74]            |     r2 = "_d:_d";
    0x00011c04 ldr r1, [pc, 0x74]            |     r1 = "libubi";
    0x00011c08 str r3, [r0]                  |     *(r0) = r3;
    0x00011c0c ldr r0, [pc, 0x70]            |     
    0x00011c10 mov r3, r6                    |     r3 = r6;
    0x00011c14 ldr r0, [r0]                  |     r0 = "%s: error!: \"%s\" does not have major:minor format\n";
    0x00011c18 bl 0x10a64                    |     fprintf ("%s: error!: \"%s\" does not have major:minor format\n", "libubi", "_d:_d", r3)
                                             | label_0:
    0x00011c1c mvn r0, 0                     |     r0 = ~0;
                                             |     do {
                                             | label_1:
    0x00011c20 add sp, sp, 0x40              |         
    0x00011c24 pop {r4, r5, r6, pc}          |         
                                             | label_2:
    0x00011c28 ldr r3, [r4]                  |         r3 = *(r4);
    0x00011c2c cmp r3, 0                     |         
                                             |         if (r3 < 0) {
    0x00011c30 blt 0x11c44                   |             goto label_3;
                                             |         }
    0x00011c34 ldr r3, [r5]                  |         r3 = *(r5);
    0x00011c38 cmp r3, 0                     |         
                                             |         if (r3 < 0) {
    0x00011c3c movge r0, 0                   |             r0 = 0;
                                             |         }
    0x00011c40 bge 0x11c20                   |         
                                             |     } while (r3 >= 0);
                                             | label_3:
    0x00011c44 bl 0x10b24                    |     errno_location ();
    0x00011c48 mov r3, 0x16                  |     r3 = 0x16;
    0x00011c4c ldr r2, [pc, 0x28]            |     r2 = "_d:_d";
    0x00011c50 ldr r1, [pc, 0x30]            |     r1 = stderr;
    0x00011c54 str r3, [r0]                  |     *(r0) = r3;
    0x00011c58 ldr r0, [pc, 0x24]            |     
    0x00011c5c ldr r3, [r5]                  |     r3 = *(r5);
    0x00011c60 str r6, [sp, 4]               |     var_4h = r6;
    0x00011c64 str r3, [sp]                  |     *(sp) = r3;
    0x00011c68 ldr r3, [r4]                  |     r3 = *(r4);
    0x00011c6c ldr r0, [r0]                  |     r0 = "%s: error!: \"%s\" does not have major:minor format\n";
    0x00011c70 bl 0x10a64                    |     fprintf ("%s: error!: \"%s\" does not have major:minor format\n", r1, "_d:_d", r3, r4, r5, r6)
    0x00011c74 b 0x11c1c                     |     goto label_0;
                                             | }
    ; assembly                                       | /* r2dec pseudo code output */
                                                     | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x11ce0 */
                                                     | #include <stdint.h>
                                                     |  
    ; (fcn) fcn.00011ce0 ()                          | void fcn_00011ce0 (int32_t arg1) {
                                                     |     int32_t var_0h;
                                                     |     int32_t var_4h;
                                                     |     r0 = arg1;
    0x00011ce0 push {r0, r1, r4, r5, r6, lr}         |     
    0x00011ce4 ldr r5, [pc, 0x50]                    |     
    0x00011ce8 mov r6, r0                            |     r6 = r0;
    0x00011cec bl 0x10b24                            |     errno_location ();
    0x00011cf0 mov r3, r6                            |     r3 = r6;
    0x00011cf4 ldr r2, [pc, 0x44]                    |     r2 = stderr;
    0x00011cf8 ldr r1, [pc, 0x44]                    |     r1 = "libubi";
    0x00011cfc ldr r4, [r0]                          |     r4 = *(r0);
    0x00011d00 ldr r0, [r5]                          |     r0 = *(0x11d38);
    0x00011d04 bl 0x10a64                            |     fprintf (r0, "libubi", r2, r3, r4)
    0x00011d08 mov r0, r4                            |     r0 = r4;
    0x00011d0c ldr r5, [r5]                          |     r5 = *(0x11d38);
    0x00011d10 bl 0x109d4                            |     strerror (r0);
    0x00011d14 str r4, [sp]                          |     *(sp) = r4;
    0x00011d18 ldr r3, [pc, 0x28]                    |     r3 = "%s: error!: cannot open \"%s\"\n";
    0x00011d1c mov r2, 8                             |     r2 = 8;
    0x00011d20 ldr r1, [pc, 0x24]                    |     r1 = *(0x11d48);
    0x00011d24 str r0, [sp, 4]                       |     var_4h = r0;
    0x00011d28 mov r0, r5                            |     r0 = r5;
    0x00011d2c bl 0x10a64                            |     fprintf (r0, r1, r2, "%s: error!: cannot open \"%s\"\n", r4)
    0x00011d30 mvn r0, 0                             |     r0 = ~0;
    0x00011d34 add sp, sp, 8                         |     
    0x00011d38 pop {r4, r5, r6, pc}                  |     
                                                     | }
    ; assembly                                           | /* r2dec pseudo code output */
                                                         | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x11e74 */
                                                         | #include <stdint.h>
                                                         |  
    ; (fcn) fcn.00011e74 ()                              | void fcn_00011e74 () {
                                                         |     int32_t var_0h;
                                                         |     int32_t var_4h;
                                                         |     int32_t var_ch;
                                                         |     int32_t var_10h;
    0x00011e74 push {r0, r1, r2, r3, r4, r5, r6, lr}     |     
    0x00011e78 mov r1, 0x68                              |     r1 = 0x68;
    0x00011e7c mov r0, 1                                 |     r0 = 1;
    0x00011e80 bl 0x10a58                                |     r0 = calloc (r0, r1);
    0x00011e84 subs r4, r0, 0                            |     r4 = r0 - 0;
                                                         |     if (r4 == r0) {
    0x00011e88 beq 0x11ef8                               |         goto label_1;
                                                         |     }
    0x00011e8c ldr r1, [pc, 0x2fc]                       |     r1 = *(0x1218c);
    0x00011e90 ldr r0, [pc, 0x2fc]                       |     r0 = "class/misc/ubi_ctrl/";
    0x00011e94 bl 0x119cc                                |     r0 = fcn_000119cc ("class/misc/ubi_ctrl/", r1);
    0x00011e98 cmp r0, 0                                 |     
    0x00011e9c str r0, [r4, 4]                           |     *((r4 + 4)) = r0;
                                                         |     if (r0 == 0) {
    0x00011ea0 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011ea4 ldr r1, [pc, 0x2ec]                       |     r1 = "_sys";
    0x00011ea8 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "_sys");
    0x00011eac cmp r0, 0                                 |     
    0x00011eb0 str r0, [r4, 8]                           |     *((r4 + 8)) = r0;
                                                         |     if (r0 == 0) {
    0x00011eb4 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011eb8 ldr r1, [pc, 0x2dc]                       |     r1 = *(0x12198);
    0x00011ebc ldr r0, [pc, 0x2d0]                       |     r0 = "class/misc/ubi_ctrl/";
    0x00011ec0 bl 0x119cc                                |     r0 = fcn_000119cc ("class/misc/ubi_ctrl/", r1);
    0x00011ec4 cmp r0, 0                                 |     
    0x00011ec8 str r0, [r4, 0xc]                         |     *((r4 + 0xc)) = r0;
                                                         |     if (r0 == 0) {
    0x00011ecc beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011ed0 mov r1, 0                                 |     r1 = 0;
    0x00011ed4 bl 0x10af4                                |     r0 = open64 ();
    0x00011ed8 cmn r0, 1                                 |     
                                                         |     if (r0 != 1) {
    0x00011edc bne 0x11f04                               |         goto label_2;
                                                         |     }
    0x00011ee0 bl 0x10b24                                |     errno_location ();
    0x00011ee4 mov r3, 0                                 |     r3 = 0;
    0x00011ee8 str r3, [r0]                              |     *(r0) = r3;
                                                         |     do {
                                                         | label_0:
    0x00011eec mov r0, r4                                |         r0 = r4;
    0x00011ef0 bl 0x11da0                                |         fcn_00011da0 (r0);
    0x00011ef4 mov r4, 0                                 |         r4 = 0;
                                                         | label_1:
    0x00011ef8 mov r0, r4                                |         r0 = r4;
    0x00011efc add sp, sp, 0x10                          |         
    0x00011f00 pop {r4, r5, r6, pc}                      |         
                                                         | label_2:
    0x00011f04 bl 0x10b6c                                |         r0 = close (r0);
    0x00011f08 cmp r0, 0                                 |         
                                                         |         if (r0 == 0) {
    0x00011f0c beq 0x11f5c                               |             goto label_3;
                                                         |         }
    0x00011f10 bl 0x10b24                                |         errno_location ();
    0x00011f14 ldr r6, [pc, 0x284]                       |         
    0x00011f18 ldr r3, [r4, 0xc]                         |         r3 = *((r4 + 0xc));
    0x00011f1c ldr r2, [pc, 0x280]                       |         r2 = stderr;
    0x00011f20 ldr r1, [pc, 0x280]                       |         r1 = "libubi";
    0x00011f24 ldr r5, [r0]                              |         r5 = *(r0);
    0x00011f28 ldr r0, [r6]                              |         r0 = "class/ubi";
    0x00011f2c bl 0x10a64                                |         fprintf ("class/ubi", "libubi", r2, r3, r4, r5, "class/ubi")
    0x00011f30 mov r0, r5                                |         r0 = r5;
    0x00011f34 ldr r6, [r6]                              |         r6 = "class/ubi";
    0x00011f38 bl 0x109d4                                |         strerror (r0);
    0x00011f3c str r5, [sp]                              |         *(sp) = r5;
    0x00011f40 ldr r3, [pc, 0x264]                       |         r3 = "_s:_error_:_close_failed_on___s_";
    0x00011f44 mov r2, 8                                 |         r2 = 8;
    0x00011f48 ldr r1, [pc, 0x260]                       |         r1 = *(0x121ac);
    0x00011f4c str r0, [sp, 4]                           |         var_4h = r0;
    0x00011f50 mov r0, r6                                |         r0 = r6;
    0x00011f54 bl 0x10a64                                |         fprintf (r0, r1, r2, "_s:_error_:_close_failed_on___s_", r4, r5)
    0x00011f58 b 0x11eec                                 |         
                                                         |     } while (1);
                                                         | label_3:
    0x00011f5c ldr r1, [pc, 0x250]                       |     r1 = "_serror__d___s_";
    0x00011f60 ldr r0, [r4, 0xc]                         |     r0 = *((r4 + 0xc));
    0x00011f64 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "_serror__d___s_");
    0x00011f68 cmp r0, 0                                 |     
    0x00011f6c str r0, [r4, 0x10]                        |     *((r4 + 0x10)) = r0;
                                                         |     if (r0 == 0) {
    0x00011f70 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011f74 ldr r1, [pc, 0x23c]                       |     r1 = "ubi%d";
    0x00011f78 ldr r0, [r4, 0xc]                         |     r0 = *((r4 + 0xc));
    0x00011f7c bl 0x119cc                                |     r0 = fcn_000119cc (r0, "ubi%d");
    0x00011f80 cmp r0, 0                                 |     
    0x00011f84 str r0, [r4, 0x14]                        |     *((r4 + 0x14)) = r0;
                                                         |     if (r0 == 0) {
    0x00011f88 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011f8c ldr r1, [pc, 0x204]                       |     r1 = "_sys";
    0x00011f90 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x00011f94 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "_sys");
    0x00011f98 cmp r0, 0                                 |     
    0x00011f9c str r0, [r4, 0x18]                        |     *((r4 + 0x18)) = r0;
                                                         |     if (r0 == 0) {
    0x00011fa0 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011fa4 ldr r1, [pc, 0x210]                       |     r1 = "version";
    0x00011fa8 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x00011fac bl 0x119cc                                |     r0 = fcn_000119cc (r0, "version");
    0x00011fb0 cmp r0, 0                                 |     
    0x00011fb4 str r0, [r4, 0x1c]                        |     *((r4 + 0x1c)) = r0;
                                                         |     if (r0 == 0) {
    0x00011fb8 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011fbc ldr r1, [pc, 0x1fc]                       |     r1 = "avail_eraseblocks";
    0x00011fc0 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x00011fc4 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "avail_eraseblocks");
    0x00011fc8 cmp r0, 0                                 |     
    0x00011fcc str r0, [r4, 0x20]                        |     *((r4 + 0x20)) = r0;
                                                         |     if (r0 == 0) {
    0x00011fd0 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011fd4 ldr r1, [pc, 0x1e8]                       |     r1 = "total_eraseblocks";
    0x00011fd8 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x00011fdc bl 0x119cc                                |     r0 = fcn_000119cc (r0, "total_eraseblocks");
    0x00011fe0 cmp r0, 0                                 |     
    0x00011fe4 str r0, [r4, 0x24]                        |     *((r4 + 0x24)) = r0;
                                                         |     if (r0 == 0) {
    0x00011fe8 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00011fec ldr r1, [pc, 0x1d4]                       |     r1 = "bad_peb_count";
    0x00011ff0 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x00011ff4 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "bad_peb_count");
    0x00011ff8 cmp r0, 0                                 |     
    0x00011ffc str r0, [r4, 0x28]                        |     *((r4 + 0x28)) = r0;
                                                         |     if (r0 == 0) {
    0x00012000 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012004 ldr r1, [pc, 0x1c0]                       |     r1 = "eraseblock_size";
    0x00012008 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x0001200c bl 0x119cc                                |     r0 = fcn_000119cc (r0, "eraseblock_size");
    0x00012010 cmp r0, 0                                 |     
    0x00012014 str r0, [r4, 0x2c]                        |     *((r4 + 0x2c)) = r0;
                                                         |     if (r0 == 0) {
    0x00012018 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x0001201c ldr r1, [pc, 0x1ac]                       |     r1 = "max_ec";
    0x00012020 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x00012024 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "max_ec");
    0x00012028 cmp r0, 0                                 |     
    0x0001202c str r0, [r4, 0x30]                        |     *((r4 + 0x30)) = r0;
                                                         |     if (r0 == 0) {
    0x00012030 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012034 ldr r1, [pc, 0x198]                       |     r1 = "reserved_for_bad";
    0x00012038 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x0001203c bl 0x119cc                                |     r0 = fcn_000119cc (r0, "reserved_for_bad");
    0x00012040 cmp r0, 0                                 |     
    0x00012044 str r0, [r4, 0x34]                        |     *((r4 + 0x34)) = r0;
                                                         |     if (r0 == 0) {
    0x00012048 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x0001204c ldr r1, [pc, 0x184]                       |     r1 = "max_vol_count";
    0x00012050 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x00012054 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "max_vol_count");
    0x00012058 cmp r0, 0                                 |     
    0x0001205c str r0, [r4, 0x38]                        |     *((r4 + 0x38)) = r0;
                                                         |     if (r0 == 0) {
    0x00012060 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012064 ldr r1, [pc, 0x170]                       |     r1 = "min_io_size";
    0x00012068 ldr r0, [r4, 0x10]                        |     r0 = *((r4 + 0x10));
    0x0001206c bl 0x119cc                                |     r0 = fcn_000119cc (r0, "min_io_size");
    0x00012070 cmp r0, 0                                 |     
    0x00012074 str r0, [r4, 0x3c]                        |     *((r4 + 0x3c)) = r0;
                                                         |     if (r0 == 0) {
    0x00012078 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x0001207c ldr r1, [pc, 0x15c]                       |     r1 = "mtd_num";
    0x00012080 ldr r0, [r4, 0xc]                         |     r0 = *((r4 + 0xc));
    0x00012084 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "mtd_num");
    0x00012088 cmp r0, 0                                 |     
    0x0001208c str r0, [r4, 0x40]                        |     *((r4 + 0x40)) = r0;
                                                         |     if (r0 == 0) {
    0x00012090 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012094 ldr r1, [pc, 0x148]                       |     r1 = "ubi%d_%d";
    0x00012098 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "ubi%d_%d");
    0x0001209c cmp r0, 0                                 |     
    0x000120a0 str r0, [r4, 0x44]                        |     *((r4 + 0x44)) = r0;
                                                         |     if (r0 == 0) {
    0x000120a4 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x000120a8 ldr r1, [pc, 0xe8]                        |     r1 = "_sys";
    0x000120ac ldr r0, [r4, 0x40]                        |     r0 = *((r4 + 0x40));
    0x000120b0 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "_sys");
    0x000120b4 cmp r0, 0                                 |     
    0x000120b8 str r0, [r4, 0x48]                        |     *((r4 + 0x48)) = r0;
                                                         |     if (r0 == 0) {
    0x000120bc beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x000120c0 ldr r1, [pc, 0x120]                       |     r1 = "type";
    0x000120c4 ldr r0, [r4, 0x40]                        |     r0 = *((r4 + 0x40));
    0x000120c8 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "type");
    0x000120cc cmp r0, 0                                 |     
    0x000120d0 str r0, [r4, 0x4c]                        |     *((r4 + 0x4c)) = r0;
                                                         |     if (r0 == 0) {
    0x000120d4 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x000120d8 ldr r1, [pc, 0x10c]                       |     r1 = "alignment";
    0x000120dc ldr r0, [r4, 0x40]                        |     r0 = *((r4 + 0x40));
    0x000120e0 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "alignment");
    0x000120e4 cmp r0, 0                                 |     
    0x000120e8 str r0, [r4, 0x50]                        |     *((r4 + 0x50)) = r0;
                                                         |     if (r0 == 0) {
    0x000120ec beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x000120f0 ldr r1, [pc, 0xf8]                        |     r1 = "data_bytes";
    0x000120f4 ldr r0, [r4, 0x40]                        |     r0 = *((r4 + 0x40));
    0x000120f8 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "data_bytes");
    0x000120fc cmp r0, 0                                 |     
    0x00012100 str r0, [r4, 0x54]                        |     *((r4 + 0x54)) = r0;
                                                         |     if (r0 == 0) {
    0x00012104 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012108 ldr r1, [pc, 0xe4]                        |     r1 = "reserved_ebs";
    0x0001210c ldr r0, [r4, 0x40]                        |     r0 = *((r4 + 0x40));
    0x00012110 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "reserved_ebs");
    0x00012114 cmp r0, 0                                 |     
    0x00012118 str r0, [r4, 0x58]                        |     *((r4 + 0x58)) = r0;
                                                         |     if (r0 == 0) {
    0x0001211c beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012120 ldr r1, [pc, 0xd0]                        |     r1 = "usable_eb_size";
    0x00012124 ldr r0, [r4, 0x40]                        |     r0 = *((r4 + 0x40));
    0x00012128 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "usable_eb_size");
    0x0001212c cmp r0, 0                                 |     
    0x00012130 str r0, [r4, 0x5c]                        |     *((r4 + 0x5c)) = r0;
                                                         |     if (r0 == 0) {
    0x00012134 beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012138 ldr r1, [pc, 0xbc]                        |     r1 = "corrupted";
    0x0001213c ldr r0, [r4, 0x40]                        |     r0 = *((r4 + 0x40));
    0x00012140 bl 0x119cc                                |     r0 = fcn_000119cc (r0, "corrupted");
    0x00012144 cmp r0, 0                                 |     
    0x00012148 str r0, [r4, 0x60]                        |     *((r4 + 0x60)) = r0;
                                                         |     if (r0 == 0) {
    0x0001214c beq 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012150 add r1, sp, 0xc                           |     r1 += var_ch;
    0x00012154 ldr r0, [r4, 0x14]                        |     r0 = *((r4 + 0x14));
    0x00012158 bl 0x1172c                                |     r0 = fcn_0001172c (r0, r1);
    0x0001215c cmp r0, 0                                 |     
                                                         |     if (r0 != 0) {
    0x00012160 bne 0x11eec                               |         goto label_0;
                                                         |     }
    0x00012164 ldr r3, [sp, 0xc]                         |     r3 = var_ch;
    0x00012168 cmp r3, 1                                 |     
                                                         |     if (r3 == 1) {
    0x0001216c beq 0x11ef8                               |         goto label_1;
                                                         |     }
    0x00012170 ldr r0, [pc, 0x28]                        |     
    0x00012174 str r3, [sp]                              |     *(sp) = r3;
    0x00012178 ldr r2, [pc, 0x24]                        |     r2 = stderr;
    0x0001217c mov r3, 1                                 |     r3 = 1;
    0x00012180 ldr r1, [pc, 0x78]                        |     r1 = "name";
    0x00012184 ldr r0, [r0]                              |     r0 = "class/ubi";
    0x00012188 bl 0x10a64                                |     fprintf ("class/ubi", "name", r2, r3)
    0x0001218c b 0x11eec                                 |     goto label_0;
                                                         | }
    ; assembly                                           | /* r2dec pseudo code output */
                                                         | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x12330 */
                                                         | #include <stdint.h>
                                                         |  
    ; (fcn) fcn.00012330 ()                              | void fcn_00012330 (int32_t arg1, void * s) {
                                                         |     int32_t var_0h;
                                                         |     int32_t var_4h;
                                                         |     int32_t var_ch;
                                                         |     int32_t var_10h;
                                                         |     int32_t var_110h;
                                                         |     r0 = arg1;
                                                         |     r1 = s;
    0x00012330 push {r4, r5, r6, r7, r8, sb, sl, lr}     |     
    0x00012334 mov r4, r1                                |     r4 = r1;
    0x00012338 sub sp, sp, 0x110                         |     
    0x0001233c mov r5, r0                                |     r5 = r0;
    0x00012340 mov r2, 0x18                              |     r2 = 0x18;
    0x00012344 mov r1, 0                                 |     r1 = 0;
    0x00012348 mov r0, r4                                |     r0 = r4;
    0x0001234c bl 0x10adc                                |     memset (r0, r1, r2);
    0x00012350 add r2, r4, 0x14                          |     r2 = r4 + 0x14;
    0x00012354 add r1, r4, 0x10                          |     r1 = r4 + 0x10;
    0x00012358 ldr r0, [r5, 8]                           |     r0 = *((r5 + 8));
    0x0001235c bl 0x11bb4                                |     r0 = fcn_00011bb4 (r0, r1);
    0x00012360 cmp r0, 0                                 |     
                                                         |     if (r0 == 0) {
    0x00012364 mvnne r3, 0                               |         r3 = ~0;
                                                         |     }
                                                         |     if (r0 == 0) {
    0x00012368 strne r3, [r4, 0x14]                      |         *((r4 + 0x14)) = r3;
                                                         |     }
                                                         |     if (r0 == 0) {
    0x0001236c strne r3, [r4, 0x10]                      |         *((r4 + 0x10)) = r3;
                                                         |     }
    0x00012370 ldr r0, [r5, 0xc]                         |     r0 = *((r5 + 0xc));
    0x00012374 bl 0x10b00                                |     r0 = opendir ();
    0x00012378 subs r8, r0, 0                            |     r8 = r0 - 0;
                                                         |     if (r8 == r0) {
    0x0001237c beq 0x124dc                               |         goto label_2;
                                                         |     }
    0x00012380 mvn r3, 0x80000000                        |     r3 = ~0x80000000;
    0x00012384 str r3, [r4, 4]                           |     *((r4 + 4)) = r3;
    0x00012388 bl 0x10b24                                |     errno_location ();
    0x0001238c ldr sl, [pc, 0x17c]                       |     sl = "ubi%d%s";
    0x00012390 mov sb, 0                                 |     sb = 0;
    0x00012394 mov r7, r0                                |     r7 = r0;
                                                         |     do {
                                                         | label_0:
    0x00012398 str sb, [r7]                              |         *(r7) = sb;
    0x0001239c mov r0, r8                                |         r0 = r8;
    0x000123a0 bl 0x10aa0                                |         r0 = readdir64 ();
    0x000123a4 cmp r0, 0                                 |         
                                                         |         if (r0 == 0) {
    0x000123a8 beq 0x12438                               |             goto label_3;
                                                         |         }
    0x000123ac add r6, r0, 0x13                          |         r6 = r0 + 0x13;
    0x000123b0 mov r0, r6                                |         r0 = r6;
    0x000123b4 bl 0x10b3c                                |         r0 = strlen (r0);
    0x000123b8 cmp r0, 0xfe                              |         
                                                         |         if (r0 >= 0xfe) {
    0x000123bc bls 0x123f0                               |             
    0x000123c0 ldr r0, [pc, 0x14c]                       |             
    0x000123c4 str r6, [sp]                              |             *(sp) = r6;
    0x000123c8 ldr r2, [pc, 0x148]                       |             r2 = stderr;
    0x000123cc ldr r3, [r5, 0xc]                         |             r3 = *((r5 + 0xc));
    0x000123d0 ldr r1, [pc, 0x144]                       |             r1 = "libubi";
    0x000123d4 ldr r0, [r0]                              |             r0 = "ubi%d%s";
    0x000123d8 bl 0x10a64                                |             fprintf ("ubi%d%s", "libubi", r2, r3, r4, r5, r6)
    0x000123dc mov r3, 0x16                              |             r3 = 0x16;
    0x000123e0 str r3, [r7]                              |             *(r7) = r3;
                                                         | label_1:
    0x000123e4 mov r0, r8                                |             r0 = r8;
    0x000123e8 bl 0x10b54                                |             closedir ();
    0x000123ec b 0x124dc                                 |             goto label_2;
                                                         |         }
    0x000123f0 add r3, sp, 0x10                          |         r3 += var_10h;
    0x000123f4 add r2, sp, 0xc                           |         r2 += var_ch;
    0x000123f8 mov r1, sl                                |         r1 = sl;
    0x000123fc mov r0, r6                                |         r0 = r6;
    0x00012400 bl 0x10aac                                |         r0 = sscanf (r0, r1, r2);
    0x00012404 cmp r0, 1                                 |         
    0x00012408 bne 0x12398                               |         
                                                         |     } while (r0 != 1);
    0x0001240c ldr r3, [r4]                              |     r3 = *(r4);
    0x00012410 ldr r2, [r4, 8]                           |     r2 = *((r4 + 8));
    0x00012414 add r3, r3, 1                             |     r3++;
    0x00012418 str r3, [r4]                              |     *(r4) = r3;
    0x0001241c ldr r3, [sp, 0xc]                         |     r3 = var_ch;
    0x00012420 cmp r2, r3                                |     
    0x00012424 ldr r2, [r4, 4]                           |     r2 = *((r4 + 4));
                                                         |     if (r2 >= r3) {
    0x00012428 strlt r3, [r4, 8]                         |         *((r4 + 8)) = r3;
                                                         |     }
    0x0001242c cmp r3, r2                                |     
                                                         |     if (r3 >= r2) {
    0x00012430 strlt r3, [r4, 4]                         |         *((r4 + 4)) = r3;
                                                         |     }
    0x00012434 b 0x12398                                 |     goto label_0;
                                                         | label_3:
    0x00012438 ldr r6, [r7]                              |     r6 = *(r7);
    0x0001243c cmp r6, 0                                 |     
                                                         |     if (r6 != 0) {
    0x00012440 beq 0x12488                               |         
    0x00012444 ldr r4, [pc, 0xc8]                        |         
    0x00012448 ldr r3, [r5, 0xc]                         |         r3 = *((r5 + 0xc));
    0x0001244c ldr r2, [pc, 0xc4]                        |         r2 = stderr;
    0x00012450 ldr r1, [pc, 0xc8]                        |         r1 = "_s:_error_:_invalid_entry_in__s:___s_";
    0x00012454 ldr r0, [r4]                              |         r0 = "ubi%d%s";
    0x00012458 bl 0x10a64                                |         fprintf ("ubi%d%s", "_s:_error_:_invalid_entry_in__s:___s_", r2, r3, "ubi%d%s")
    0x0001245c mov r0, r6                                |         r0 = r6;
    0x00012460 ldr r4, [r4]                              |         r4 = "ubi%d%s";
    0x00012464 bl 0x109d4                                |         strerror (r0);
    0x00012468 str r6, [sp]                              |         *(sp) = r6;
    0x0001246c ldr r3, [pc, 0xb0]                        |         r3 = "%s: error!: readdir failed on \"%s\"\n";
    0x00012470 mov r2, 8                                 |         r2 = 8;
    0x00012474 ldr r1, [pc, 0xac]                        |         r1 = *(0x12524);
    0x00012478 str r0, [sp, 4]                           |         var_4h = r0;
    0x0001247c mov r0, r4                                |         r0 = r4;
    0x00012480 bl 0x10a64                                |         fprintf (r0, r1, r2, "%s: error!: readdir failed on \"%s\"\n", r4, r5, r6)
    0x00012484 b 0x123e4                                 |         goto label_1;
                                                         |     }
    0x00012488 mov r0, r8                                |     r0 = r8;
    0x0001248c bl 0x10b54                                |     r0 = closedir ();
    0x00012490 cmp r0, 0                                 |     
                                                         |     if (r0 != 0) {
    0x00012494 beq 0x124e4                               |         
    0x00012498 ldr r6, [pc, 0x74]                        |         r6 = "ubi%d%s";
    0x0001249c ldr r4, [r7]                              |         r4 = *(r7);
    0x000124a0 ldr r3, [r5, 0xc]                         |         r3 = *((r5 + 0xc));
    0x000124a4 ldr r2, [pc, 0x6c]                        |         r2 = stderr;
    0x000124a8 ldr r1, [pc, 0x7c]                        |         r1 = "_serror__d___s_";
    0x000124ac ldr r0, [r6]                              |         r0 = "ubi%d%s";
    0x000124b0 bl 0x10a64                                |         fprintf ("ubi%d%s", "_serror__d___s_", r2, r3, r4, r5, "ubi%d%s")
    0x000124b4 mov r0, r4                                |         r0 = r4;
    0x000124b8 ldr r5, [r6]                              |         r5 = "ubi%d%s";
    0x000124bc bl 0x109d4                                |         strerror (r0);
    0x000124c0 str r4, [sp]                              |         *(sp) = r4;
    0x000124c4 ldr r3, [pc, 0x58]                        |         r3 = "%s: error!: readdir failed on \"%s\"\n";
    0x000124c8 mov r2, 8                                 |         r2 = 8;
    0x000124cc ldr r1, [pc, 0x54]                        |         r1 = *(0x12524);
    0x000124d0 str r0, [sp, 4]                           |         var_4h = r0;
    0x000124d4 mov r0, r5                                |         r0 = r5;
    0x000124d8 bl 0x10a64                                |         fprintf (r0, r1, r2, "%s: error!: readdir failed on \"%s\"\n", r4)
                                                         | label_2:
    0x000124dc mvn r0, 0                                 |         r0 = ~0;
    0x000124e0 b 0x12508                                 |         
                                                         |     } else {
    0x000124e4 ldr r3, [r4, 4]                           |         r3 = *((r4 + 4));
    0x000124e8 add r1, r4, 0xc                           |         r1 = r4 + 0xc;
    0x000124ec cmn r3, 0x80000001                        |         
                                                         |         if (r3 != 0x80000001) {
    0x000124f0 streq r0, [r4, 4]                         |             *((r4 + 4)) = r0;
                                                         |         }
    0x000124f4 ldr r0, [r5, 0x14]                        |         r0 = *((r5 + 0x14));
    0x000124f8 bl 0x1172c                                |         r0 = fcn_0001172c (r0, r1);
    0x000124fc adds r0, r0, 0                            |         r0 += 0;
                                                         |         if (r0 == r0) {
    0x00012500 movne r0, 1                               |             r0 = 1;
                                                         |         }
    0x00012504 rsb r0, r0, 0                             |         r0 -= ;
                                                         |     }
    0x00012508 add sp, sp, 0x110                         |     
    0x0001250c pop {r4, r5, r6, r7, r8, sb, sl, pc}      |     
                                                         | }
    ; assembly                                               | /* r2dec pseudo code output */
                                                             | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x12660 */
                                                             | #include <stdint.h>
                                                             |  
                                                             | #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
                                                             |  
    ; (fcn) fcn.00012660 ()                                  | void fcn_00012660 (int32_t arg2, char * s) {
                                                             |     int32_t var_b4h;
                                                             |     int32_t var_ach;
                                                             |     int32_t var_a8h;
                                                             |     int32_t var_a4h;
                                                             |     int32_t var_a0h;
                                                             |     int32_t var_9ch;
                                                             |     int32_t var_8ch;
                                                             |     int32_t var_7ch;
                                                             |     int32_t var_6ch;
                                                             |     int32_t var_0h;
                                                             |     int32_t var_4h;
                                                             |     int32_t var_sp_b4h;
                                                             |     int32_t var_sp_6ch;
                                                             |     int32_t var_20h_2;
                                                             |     int32_t var_20h;
                                                             |     r1 = arg2;
                                                             |     r0 = s;
    0x00012660 push {r4, r5, r6, r7, r8, sb, sl, fp, lr}     |     
    0x00012664 add fp, sp, 0x20                              |     
    0x00012668 sub sp, sp, 0x9c                              |     
    0x0001266c mov r6, r0                                    |     r6 = r0;
    0x00012670 ldr r0, [r0, 0x40]                            |     r0 = *((r0 + 0x40));
    0x00012674 mov r5, r1                                    |     r5 = r1;
    0x00012678 bl 0x10b3c                                    |     strlen (r0);
    0x0001267c sub r1, fp, 0x8c                              |     r1 -= var_8ch;
    0x00012680 add r0, r0, 0x6b                              |     r0 += 0x6b;
    0x00012684 bic r0, r0, 7                                 |     r0 = BIT_MASK (r0, 7);
    0x00012688 sub sp, sp, r0                                |     
    0x0001268c mov r0, r5                                    |     r0 = r5;
    0x00012690 bl 0x109e0                                    |     r0 = stat64 ();
    0x00012694 cmp r0, 0                                     |     
                                                             |     if (r0 == 0) {
    0x00012698 beq 0x126f0                                   |         goto label_5;
                                                             |     }
    0x0001269c bl 0x10b24                                    |     errno_location ();
    0x000126a0 ldr r6, [pc, 0x1e8]                           |     r6 = *(0x1288c);
    0x000126a4 mov r3, r5                                    |     r3 = r5;
    0x000126a8 ldr r2, [pc, 0x1e4]                           |     r2 = stderr;
    0x000126ac ldr r1, [pc, 0x1e4]                           |     r1 = "libubi";
    0x000126b0 ldr r4, [r0]                                  |     r4 = *(r0);
    0x000126b4 ldr r0, [r6]                                  |     r0 = *(0x1288c);
    0x000126b8 bl 0x10a64                                    |     fprintf (r0, "libubi", r2, r3, r4, r5, r6)
    0x000126bc mov r0, r4                                    |     r0 = r4;
    0x000126c0 ldr r5, [r6]                                  |     r5 = *(0x1288c);
    0x000126c4 bl 0x109d4                                    |     strerror (r0);
    0x000126c8 str r4, [sp]                                  |     *(sp) = r4;
    0x000126cc ldr r3, [pc, 0x1c8]                           |     r3 = "_s:_error_:_cannot_get_information_about___s_";
    0x000126d0 mov r2, 8                                     |     r2 = 8;
    0x000126d4 ldr r1, [pc, 0x1c4]                           |     r1 = *(0x1289c);
    0x000126d8 str r0, [sp, 4]                               |     var_4h = r0;
    0x000126dc mov r0, r5                                    |     r0 = r5;
    0x000126e0 bl 0x10a64                                    |     fprintf (r0, r1, r2, "_s:_error_:_cannot_get_information_about___s_", r4)
                                                             |     do {
                                                             | label_0:
    0x000126e4 mvn r0, 0                                     |         r0 = ~0;
                                                             | label_4:
    0x000126e8 sub sp, fp, 0x20                              |         
    0x000126ec pop {r4, r5, r6, r7, r8, sb, sl, fp, pc}      |         
                                                             | label_5:
    0x000126f0 ldr r3, [fp, -0x7c]                           |         r3 = var_7ch;
    0x000126f4 and r3, r3, 0xf000                            |         r3 &= 0xf000;
    0x000126f8 cmp r3, 0x2000                                |         
                                                             |         if (r3 == 0x2000) {
    0x000126fc beq 0x12728                                   |             goto label_6;
                                                             |         }
    0x00012700 ldr r0, [pc, 0x188]                           |         
    0x00012704 mov r3, r5                                    |         r3 = r5;
    0x00012708 ldr r2, [pc, 0x184]                           |         r2 = stderr;
    0x0001270c ldr r1, [pc, 0x190]                           |         r1 = "_serror__d___s_";
    0x00012710 ldr r0, [r0]                                  |         r0 = *(0x1288c);
    0x00012714 bl 0x10a64                                    |         r0 = fprintf (r0, "_serror__d___s_", r2, r3)
    0x00012718 bl 0x10b24                                    |         errno_location ();
    0x0001271c mov r3, 0x16                                  |         r3 = 0x16;
                                                             | label_1:
    0x00012720 str r3, [r0]                                  |         *(r0) = r3;
    0x00012724 b 0x126e4                                     |         
                                                             |     } while (1);
                                                             | label_6:
    0x00012728 ldrd r2, r3, [fp, -0x6c]                      |     __asm ("ldrd r2, r3, [var_6ch]");
    0x0001272c mov r1, r3                                    |     r1 = r3;
    0x00012730 mov r0, r2                                    |     r0 = r2;
    0x00012734 strd r2, r3, [fp, -0xb4]                      |     __asm ("strd r2, r3, [var_b4h]");
    0x00012738 bl 0x10a04                                    |     gnu_dev_major ();
    0x0001273c ldrd r2, r3, [fp, -0xb4]                      |     __asm ("ldrd r2, r3, [var_b4h]");
    0x00012740 mov r1, r3                                    |     r1 = r3;
    0x00012744 mov sb, r0                                    |     sb = r0;
    0x00012748 mov r0, r2                                    |     r0 = r2;
    0x0001274c bl 0x10a40                                    |     gnu_dev_minor ();
    0x00012750 sub r1, fp, 0xa4                              |     r1 -= var_a4h;
    0x00012754 mov r7, r0                                    |     r7 = r0;
    0x00012758 mov r0, r6                                    |     r0 = r6;
    0x0001275c bl 0x12330                                    |     r0 = fcn_00012330 (r0, r1);
    0x00012760 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012764 addeq r8, sp, 8                               |         r8 += var_b4h;
                                                             |     }
                                                             |     if (r0 != 0) {
    0x00012768 ldreq r4, [fp, -0xa0]                         |         r4 = var_a0h;
                                                             |     }
                                                             |     if (r0 == 0) {
    0x0001276c addeq sl, r6, 0x18                            |         sl = r6 + 0x18;
                                                             |         goto label_7;
                                                             |     }
                                                             |     if (r0 != 0) {
                                                             | label_7:
    0x00012770 bne 0x126e4                                   |         goto label_0;
                                                             |     }
                                                             |     do {
    0x00012774 ldr r3, [fp, -0x9c]                           |         r3 = var_9ch;
    0x00012778 cmp r4, r3                                    |         
                                                             |         if (r4 > r3) {
    0x0001277c bgt 0x127f4                                   |             goto label_8;
                                                             |         }
    0x00012780 sub r3, fp, 0xa8                              |         r3 -= var_a8h;
    0x00012784 sub r2, fp, 0xac                              |         r2 -= var_ach;
    0x00012788 mov r1, r4                                    |         r1 = r4;
    0x0001278c mov r0, sl                                    |         r0 = sl;
    0x00012790 bl 0x11c8c                                    |         r0 = fcn_00011c8c (r0, r1);
    0x00012794 cmp r0, 0                                     |         
                                                             |         if (r0 == 0) {
    0x00012798 beq 0x127e8                                   |             goto label_9;
                                                             |         }
    0x0001279c bl 0x10b24                                    |         r0 = errno_location ();
    0x000127a0 ldr r3, [r0]                                  |         r3 = *(r0);
    0x000127a4 cmp r3, 2                                     |         
                                                             |         if (r3 != 2) {
    0x000127a8 bne 0x127b4                                   |             goto label_10;
                                                             |         }
                                                             | label_2:
    0x000127ac add r4, r4, 1                                 |         r4++;
    0x000127b0 b 0x12774                                     |         
                                                             |     } while (1);
                                                             | label_10:
    0x000127b4 cmp r3, 0                                     |     
                                                             |     if (r3 != 0) {
    0x000127b8 bne 0x126e4                                   |         goto label_0;
                                                             |     }
                                                             | label_3:
    0x000127bc ldr r0, [pc, 0xcc]                            |     
    0x000127c0 mov r3, r5                                    |     r3 = r5;
    0x000127c4 str r7, [sp, 4]                               |     var_4h = r7;
    0x000127c8 str sb, [sp]                                  |     *(sp) = sb;
    0x000127cc ldr r2, [pc, 0xc0]                            |     r2 = stderr;
    0x000127d0 ldr r1, [pc, 0xd0]                            |     r1 = "%s: error!: \"%s\" is not a character device\n";
    0x000127d4 ldr r0, [r0]                                  |     r0 = *(0x1288c);
    0x000127d8 bl 0x10a64                                    |     r0 = fprintf (r0, "%s: error!: \"%s\" is not a character device\n", r2, r3)
    0x000127dc bl 0x10b24                                    |     errno_location ();
    0x000127e0 mov r3, 0x13                                  |     r3 = 0x13;
    0x000127e4 b 0x12720                                     |     goto label_1;
                                                             | label_9:
    0x000127e8 ldr r3, [fp, -0xac]                           |     r3 = var_ach;
    0x000127ec cmp r3, sb                                    |     
                                                             |     if (r3 != sb) {
    0x000127f0 bne 0x127ac                                   |         goto label_2;
                                                             |     }
                                                             | label_8:
    0x000127f4 ldr r3, [fp, -0x9c]                           |     r3 = var_9ch;
    0x000127f8 cmp r4, r3                                    |     
                                                             |     if (r4 > r3) {
    0x000127fc bgt 0x127bc                                   |         goto label_3;
                                                             |     }
    0x00012800 cmp r7, 0                                     |     
                                                             |     if (r7 == 0) {
    0x00012804 moveq r0, 1                                   |         r0 = 1;
                                                             |         goto label_11;
                                                             |     }
                                                             |     if (r7 == 0) {
                                                             | label_11:
    0x00012808 beq 0x126e8                                   |         goto label_4;
                                                             |     }
    0x0001280c sub r3, r7, 1                                 |     r3 = r7 - 1;
    0x00012810 mov r2, r4                                    |     r2 = r4;
    0x00012814 ldr r1, [r6, 0x40]                            |     r1 = *((r6 + 0x40));
    0x00012818 mov r0, r8                                    |     r0 = r8;
    0x0001281c bl 0x10b18                                    |     sprintf (r0, r1, r2);
    0x00012820 mov r1, 0                                     |     r1 = 0;
    0x00012824 mov r0, r8                                    |     r0 = r8;
    0x00012828 bl 0x10af4                                    |     r0 = open64 ();
    0x0001282c cmn r0, 1                                     |     
                                                             |     if (r0 == 1) {
    0x00012830 beq 0x127bc                                   |         goto label_3;
                                                             |     }
    0x00012834 bl 0x10b6c                                    |     r0 = close (r0);
    0x00012838 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x0001283c beq 0x12888                                   |         
    0x00012840 bl 0x10b24                                    |         errno_location ();
    0x00012844 ldr r5, [pc, 0x44]                            |         
    0x00012848 mov r3, r8                                    |         r3 = r8;
    0x0001284c ldr r2, [pc, 0x40]                            |         r2 = stderr;
    0x00012850 ldr r1, [pc, 0x54]                            |         r1 = "%s: error!: \"%s\" has major:minor %d:%d, but this does not correspond to any existing UBI device or volume\n";
    0x00012854 ldr r4, [r0]                                  |         r4 = *(r0);
    0x00012858 ldr r0, [r5]                                  |         r0 = *(0x1288c);
    0x0001285c bl 0x10a64                                    |         fprintf (r0, "%s: error!: \"%s\" has major:minor %d:%d, but this does not correspond to any existing UBI device or volume\n", r2, r3, r4, r5)
    0x00012860 mov r0, r4                                    |         r0 = r4;
    0x00012864 ldr r5, [r5]                                  |         r5 = *(0x1288c);
    0x00012868 bl 0x109d4                                    |         strerror (r0);
    0x0001286c str r4, [sp]                                  |         *(sp) = r4;
    0x00012870 ldr r3, [pc, 0x24]                            |         r3 = "_s:_error_:_cannot_get_information_about___s_";
    0x00012874 mov r2, 8                                     |         r2 = 8;
    0x00012878 ldr r1, [pc, 0x20]                            |         r1 = *(0x1289c);
    0x0001287c str r0, [sp, 4]                               |         var_4h = r0;
    0x00012880 mov r0, r5                                    |         r0 = r5;
    0x00012884 bl 0x10a64                                    |         fprintf (r0, r1, r2, "_s:_error_:_cannot_get_information_about___s_", r4)
                                                             |     }
    0x00012888 mov r0, 2                                     |     r0 = 2;
    0x0001288c b 0x126e8                                     |     goto label_4;
                                                             | }
    ; assembly                                               | /* r2dec pseudo code output */
                                                             | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x12cbc */
                                                             | #include <stdint.h>
                                                             |  
                                                             | #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
                                                             |  
    ; (fcn) fcn.00012cbc ()                                  | void fcn_00012cbc (int32_t arg1, int32_t arg2) {
                                                             |     int32_t var_128h;
                                                             |     int32_t var_124h;
                                                             |     int32_t var_0h;
                                                             |     int32_t var_4h;
                                                             |     char * s;
                                                             |     int32_t var_20h_2;
                                                             |     int32_t var_20h;
                                                             |     r0 = arg1;
                                                             |     r1 = arg2;
    0x00012cbc push {r4, r5, r6, r7, r8, sb, sl, fp, lr}     |     
    0x00012cc0 add sl, r2, 4                                 |     sl = r2 + 4;
    0x00012cc4 add fp, sp, 0x20                              |     
    0x00012cc8 sub sp, sp, 0x114                             |     
    0x00012ccc mov r6, r1                                    |     r6 = r1;
    0x00012cd0 mov r5, r0                                    |     r5 = r0;
    0x00012cd4 mov r4, r2                                    |     r4 = r2;
    0x00012cd8 mov r1, 0                                     |     r1 = 0;
    0x00012cdc mov r2, 0x54                                  |     r2 = 0x54;
    0x00012ce0 mov r0, sl                                    |     r0 = sl;
    0x00012ce4 bl 0x10adc                                    |     memset (r0, r1, r2);
    0x00012ce8 str r6, [r4]                                  |     *(r4) = r6;
    0x00012cec mov r1, r6                                    |     r1 = r6;
    0x00012cf0 mov r0, r5                                    |     r0 = r5;
    0x00012cf4 bl 0x12c68                                    |     r0 = fcn_00012c68 (r0, r1);
    0x00012cf8 cmp r0, 0                                     |     
    0x00012cfc bne 0x12d08                                   |     
                                                             |     while (r8 == r0) {
                                                             | label_0:
    0x00012d00 mvn r0, 0                                     |         r0 = ~0;
    0x00012d04 b 0x12fcc                                     |         goto label_3;
    0x00012d08 ldr r0, [r5, 0xc]                             |         r0 = *((r5 + 0xc));
    0x00012d0c bl 0x10b00                                    |         r0 = opendir ();
    0x00012d10 subs r8, r0, 0                                |         r8 = r0 - 0;
    0x00012d14 beq 0x12d00                                   |         
                                                             |     }
    0x00012d18 mvn r3, 0x80000000                            |     r3 = ~0x80000000;
    0x00012d1c str r3, [r4, 0xc]                             |     *((r4 + 0xc)) = r3;
    0x00012d20 bl 0x10b24                                    |     r0 = errno_location ();
    0x00012d24 mov sb, r0                                    |     sb = r0;
                                                             |     do {
                                                             | label_1:
    0x00012d28 mov r3, 0                                     |         r3 = 0;
    0x00012d2c str r3, [sb]                                  |         *(sb) = r3;
    0x00012d30 mov r0, r8                                    |         r0 = r8;
    0x00012d34 bl 0x10aa0                                    |         r0 = readdir64 ();
    0x00012d38 cmp r0, 0                                     |         
                                                             |         if (r0 == 0) {
    0x00012d3c beq 0x12dd8                                   |             goto label_4;
                                                             |         }
    0x00012d40 add r7, r0, 0x13                              |         r7 = r0 + 0x13;
    0x00012d44 mov r0, r7                                    |         r0 = r7;
    0x00012d48 bl 0x10b3c                                    |         r0 = strlen (r0);
    0x00012d4c cmp r0, 0xfe                                  |         
                                                             |         if (r0 >= 0xfe) {
    0x00012d50 bls 0x12d7c                                   |             
    0x00012d54 ldr r0, [pc, 0x278]                           |             
    0x00012d58 str r7, [sp]                                  |             *(sp) = r7;
    0x00012d5c ldr r2, [pc, 0x274]                           |             r2 = stderr;
    0x00012d60 ldr r3, [r5, 0xc]                             |             r3 = *((r5 + 0xc));
    0x00012d64 ldr r1, [pc, 0x270]                           |             r1 = "libubi";
    0x00012d68 ldr r0, [r0]                                  |             r0 = *(0x12fd0);
    0x00012d6c bl 0x10a64                                    |             fprintf (r0, "libubi", r2, r3)
                                                             | label_2:
    0x00012d70 mov r0, r8                                    |             r0 = r8;
    0x00012d74 bl 0x10b54                                    |             closedir ();
    0x00012d78 b 0x12d00                                     |             goto label_0;
                                                             |         }
    0x00012d7c sub r3, fp, 0x124                             |         r3 -= var_124h;
    0x00012d80 str r3, [sp]                                  |         *(sp) = r3;
    0x00012d84 sub r2, fp, 0x128                             |         r2 -= var_128h;
    0x00012d88 sub r3, fp, 0x12c                             |         r3 -= s;
    0x00012d8c ldr r1, [pc, 0x24c]                           |         r1 = "_s:_error_:_invalid_entry_in__s:___s_";
    0x00012d90 mov r0, r7                                    |         r0 = r7;
    0x00012d94 bl 0x10aac                                    |         r0 = sscanf (r0, "_s:_error_:_invalid_entry_in__s:___s_", r2);
    0x00012d98 cmp r0, 2                                     |         
    0x00012d9c bne 0x12d28                                   |         
                                                             |     } while (r0 != 2);
    0x00012da0 ldr r3, [fp, -0x128]                          |     r3 = var_128h;
    0x00012da4 cmp r3, r6                                    |     
                                                             |     if (r3 != r6) {
    0x00012da8 bne 0x12d28                                   |         goto label_1;
                                                             |     }
    0x00012dac ldr r3, [r4, 8]                               |     r3 = *((r4 + 8));
    0x00012db0 ldr r2, [r4, 0x10]                            |     r2 = *((r4 + 0x10));
    0x00012db4 add r3, r3, 1                                 |     r3++;
    0x00012db8 str r3, [r4, 8]                               |     *((r4 + 8)) = r3;
    0x00012dbc ldr r3, [fp, -0x12c]                          |     r3 = s;
    0x00012dc0 cmp r2, r3                                    |     
    0x00012dc4 ldr r2, [r4, 0xc]                             |     r2 = *((r4 + 0xc));
                                                             |     if (r2 >= r3) {
    0x00012dc8 strlt r3, [r4, 0x10]                          |         *((r4 + 0x10)) = r3;
                                                             |     }
    0x00012dcc cmp r3, r2                                    |     
                                                             |     if (r3 >= r2) {
    0x00012dd0 strlt r3, [r4, 0xc]                           |         *((r4 + 0xc)) = r3;
                                                             |     }
    0x00012dd4 b 0x12d28                                     |     goto label_1;
                                                             | label_4:
    0x00012dd8 ldr r7, [sb]                                  |     r7 = *(sb);
    0x00012ddc cmp r7, 0                                     |     
                                                             |     if (r7 != 0) {
    0x00012de0 beq 0x12e28                                   |         
    0x00012de4 ldr r4, [pc, 0x1e8]                           |         
    0x00012de8 ldr r3, [r5, 0xc]                             |         r3 = *((r5 + 0xc));
    0x00012dec ldr r2, [pc, 0x1e4]                           |         r2 = stderr;
    0x00012df0 ldr r1, [pc, 0x1ec]                           |         r1 = "ubi_d__d_s";
    0x00012df4 ldr r0, [r4]                                  |         r0 = *(0x12fd0);
    0x00012df8 bl 0x10a64                                    |         fprintf (r0, "ubi_d__d_s", r2, r3, r4)
    0x00012dfc mov r0, r7                                    |         r0 = r7;
    0x00012e00 ldr r4, [r4]                                  |         r4 = *(0x12fd0);
    0x00012e04 bl 0x109d4                                    |         strerror (r0);
    0x00012e08 str r7, [sp]                                  |         *(sp) = r7;
    0x00012e0c ldr r3, [pc, 0x1d4]                           |         r3 = "%s: error!: readdir failed on \"%s\"\n";
    0x00012e10 mov r2, 8                                     |         r2 = 8;
    0x00012e14 ldr r1, [pc, 0x1d0]                           |         r1 = *(0x12fe8);
    0x00012e18 str r0, [sp, 4]                               |         var_4h = r0;
    0x00012e1c mov r0, r4                                    |         r0 = r4;
    0x00012e20 bl 0x10a64                                    |         fprintf (r0, r1, r2, "%s: error!: readdir failed on \"%s\"\n")
    0x00012e24 b 0x12d70                                     |         goto label_2;
                                                             |     }
    0x00012e28 mov r0, r8                                    |     r0 = r8;
    0x00012e2c bl 0x10b54                                    |     r0 = closedir ();
    0x00012e30 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012e34 beq 0x12e80                                   |         
    0x00012e38 ldr r6, [pc, 0x194]                           |         r6 = *(0x12fd0);
    0x00012e3c ldr r4, [sb]                                  |         r4 = *(sb);
    0x00012e40 ldr r3, [r5, 0xc]                             |         r3 = *((r5 + 0xc));
    0x00012e44 ldr r2, [pc, 0x18c]                           |         r2 = stderr;
    0x00012e48 ldr r1, [pc, 0x1a0]                           |         r1 = "_serror__d___s_";
    0x00012e4c ldr r0, [r6]                                  |         r0 = *(0x12fd0);
    0x00012e50 bl 0x10a64                                    |         fprintf (r0, "_serror__d___s_", r2, r3, r4, r5, r6)
    0x00012e54 mov r0, r4                                    |         r0 = r4;
    0x00012e58 ldr r5, [r6]                                  |         r5 = *(0x12fd0);
    0x00012e5c bl 0x109d4                                    |         strerror (r0);
    0x00012e60 str r4, [sp]                                  |         *(sp) = r4;
    0x00012e64 ldr r3, [pc, 0x17c]                           |         r3 = "%s: error!: readdir failed on \"%s\"\n";
    0x00012e68 mov r2, 8                                     |         r2 = 8;
    0x00012e6c ldr r1, [pc, 0x178]                           |         r1 = *(0x12fe8);
    0x00012e70 str r0, [sp, 4]                               |         var_4h = r0;
    0x00012e74 mov r0, r5                                    |         r0 = r5;
    0x00012e78 bl 0x10a64                                    |         fprintf (r0, r1, r2, "%s: error!: readdir failed on \"%s\"\n", r4)
    0x00012e7c b 0x12d00                                     |         goto label_0;
                                                             |     }
    0x00012e80 ldr r3, [r4, 0xc]                             |     r3 = *((r4 + 0xc));
    0x00012e84 add r2, r4, 0x14                              |     r2 = r4 + 0x14;
    0x00012e88 cmn r3, 0x80000001                            |     
                                                             |     if (r3 != 0x80000001) {
    0x00012e8c streq r0, [r4, 0xc]                           |         *((r4 + 0xc)) = r0;
                                                             |     }
    0x00012e90 add r3, r4, 0x18                              |     r3 = r4 + 0x18;
    0x00012e94 mov r1, r6                                    |     r1 = r6;
    0x00012e98 add r0, r5, 0x18                              |     r0 = r5 + 0x18;
    0x00012e9c bl 0x11c8c                                    |     r0 = fcn_00011c8c (r0, r1);
    0x00012ea0 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012ea4 bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012ea8 mov r2, sl                                    |     r2 = sl;
    0x00012eac mov r1, r6                                    |     r1 = r6;
    0x00012eb0 ldr r0, [r5, 0x3c]                            |     r0 = *((r5 + 0x3c));
    0x00012eb4 bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012eb8 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012ebc bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012ec0 add r2, r4, 0x20                              |     r2 = r4 + 0x20;
    0x00012ec4 mov r1, r6                                    |     r1 = r6;
    0x00012ec8 ldr r0, [r5, 0x1c]                            |     r0 = *((r5 + 0x1c));
    0x00012ecc bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012ed0 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012ed4 bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012ed8 add r2, r4, 0x1c                              |     r2 = r4 + 0x1c;
    0x00012edc mov r1, r6                                    |     r1 = r6;
    0x00012ee0 ldr r0, [r5, 0x20]                            |     r0 = *((r5 + 0x20));
    0x00012ee4 bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012ee8 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012eec bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012ef0 add r2, r4, 0x38                              |     r2 = r4 + 0x38;
    0x00012ef4 mov r1, r6                                    |     r1 = r6;
    0x00012ef8 ldr r0, [r5, 0x24]                            |     r0 = *((r5 + 0x24));
    0x00012efc bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012f00 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012f04 bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012f08 add r2, r4, 0x3c                              |     r2 = r4 + 0x3c;
    0x00012f0c mov r1, r6                                    |     r1 = r6;
    0x00012f10 ldr r0, [r5, 0x28]                            |     r0 = *((r5 + 0x28));
    0x00012f14 bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012f18 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012f1c bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012f20 add r2, r4, 0x48                              |     r2 = r4 + 0x48;
    0x00012f24 mov r1, r6                                    |     r1 = r6;
    0x00012f28 ldr r0, [r5, 0x30]                            |     r0 = *((r5 + 0x30));
    0x00012f2c bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012f30 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012f34 bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012f38 ldr r8, [r5, 0x2c]                            |     r8 = *((r5 + 0x2c));
    0x00012f3c mov sb, sp                                    |     sb = sp;
    0x00012f40 mov r0, r8                                    |     r0 = r8;
    0x00012f44 bl 0x10b3c                                    |     strlen (r0);
    0x00012f48 mov r2, r6                                    |     r2 = r6;
    0x00012f4c mov r1, r8                                    |     r1 = r8;
    0x00012f50 add r0, r0, 0x39                              |     r0 += 0x39;
    0x00012f54 bic r0, r0, 7                                 |     r0 = BIT_MASK (r0, 7);
    0x00012f58 sub sp, sp, r0                                |     
    0x00012f5c add r7, sp, 8                                 |     r7 += s;
    0x00012f60 mov r0, r7                                    |     r0 = r7;
    0x00012f64 bl 0x10b18                                    |     sprintf (r0, r1, r2);
    0x00012f68 add r1, r4, 0x40                              |     r1 = r4 + 0x40;
    0x00012f6c mov r0, r7                                    |     r0 = r7;
    0x00012f70 bl 0x1157c                                    |     fcn_0001157c (r0, r1);
    0x00012f74 mov sp, sb                                    |     
    0x00012f78 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012f7c bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012f80 add r2, r4, 0x4c                              |     r2 = r4 + 0x4c;
    0x00012f84 mov r1, r6                                    |     r1 = r6;
    0x00012f88 ldr r0, [r5, 0x34]                            |     r0 = *((r5 + 0x34));
    0x00012f8c bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012f90 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012f94 bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012f98 add r2, r4, 0x50                              |     r2 = r4 + 0x50;
    0x00012f9c mov r1, r6                                    |     r1 = r6;
    0x00012fa0 ldr r0, [r5, 0x38]                            |     r0 = *((r5 + 0x38));
    0x00012fa4 bl 0x117a0                                    |     r0 = fcn_000117a0 (r0, r1);
    0x00012fa8 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00012fac bne 0x12d00                                   |         goto label_0;
                                                             |     }
    0x00012fb0 ldr r3, [r4, 0x3c]                            |     r3 = *((r4 + 0x3c));
    0x00012fb4 ldr r2, [r4, 0x20]                            |     r2 = *((r4 + 0x20));
    0x00012fb8 smull r6, r7, r2, r3                          |     r6:r7 = r2 * r3;
    0x00012fbc ldr r2, [r4, 0x1c]                            |     r2 = *((r4 + 0x1c));
    0x00012fc0 strd r6, r7, [r4, 0x30]                       |     __asm ("strd r6, r7, [r4, 0x30]");
    0x00012fc4 smull r6, r7, r2, r3                          |     r6:r7 = r2 * r3;
    0x00012fc8 strd r6, r7, [r4, 0x28]                       |     __asm ("strd r6, r7, [r4, 0x28]");
                                                             | label_3:
    0x00012fcc sub sp, fp, 0x20                              |     
    0x00012fd0 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc}      |     
                                                             | }
    ; assembly                                               | /* r2dec pseudo code output */
                                                             | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x131e4 */
                                                             | #include <stdint.h>
                                                             |  
                                                             | #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
                                                             |  
    ; (fcn) fcn.000131e4 ()                                  | void fcn_000131e4 (int32_t arg1, int32_t arg2) {
                                                             |     char * s1;
                                                             |     int32_t var_0h;
                                                             |     int32_t var_20h_2;
                                                             |     int32_t var_20h;
                                                             |     r0 = arg1;
                                                             |     r1 = arg2;
    0x000131e4 push {r4, r5, r6, r7, r8, sb, sl, fp, lr}     |     
    0x000131e8 add sb, r3, 8                                 |     sb = r3 + 8;
    0x000131ec add fp, sp, 0x20                              |     
    0x000131f0 sub sp, sp, 0x3c                              |     
    0x000131f4 mov r5, r1                                    |     r5 = r1;
    0x000131f8 mov r6, r2                                    |     r6 = r2;
    0x000131fc mov r1, 0                                     |     r1 = 0;
    0x00013200 mov r2, 0xb0                                  |     r2 = 0xb0;
    0x00013204 mov r7, r0                                    |     r7 = r0;
    0x00013208 mov r0, sb                                    |     r0 = sb;
    0x0001320c mov r4, r3                                    |     r4 = r3;
    0x00013210 bl 0x10adc                                    |     memset (r0, r1, r2);
    0x00013214 ldr sl, [r7, 0x48]                            |     sl = *((r7 + 0x48));
    0x00013218 stm r4, {r5, r6}                              |     *(r4) = r5;
                                                             |     *((r4 + 4)) = r6;
    0x0001321c mov r0, sl                                    |     r0 = sl;
    0x00013220 bl 0x10b3c                                    |     strlen (r0);
    0x00013224 mov r8, sp                                    |     r8 = sp;
    0x00013228 mov r3, r6                                    |     r3 = r6;
    0x0001322c mov r2, r5                                    |     r2 = r5;
    0x00013230 mov r1, sl                                    |     r1 = sl;
    0x00013234 add r0, r0, 0x6b                              |     r0 += 0x6b;
    0x00013238 bic r0, r0, 7                                 |     r0 = BIT_MASK (r0, 7);
    0x0001323c sub sp, sp, r0                                |     
    0x00013240 mov r0, sp                                    |     r0 = sp;
    0x00013244 bl 0x10b18                                    |     sprintf (r0, r1, r2);
    0x00013248 mov r0, sp                                    |     r0 = sp;
    0x0001324c add r2, r4, 0xc                               |     r2 = r4 + 0xc;
    0x00013250 mov r1, sb                                    |     r1 = sb;
    0x00013254 bl 0x11bb4                                    |     fcn_00011bb4 (r0, r1);
    0x00013258 mov sp, r8                                    |     
    0x0001325c cmp r0, 0                                     |     
    0x00013260 beq 0x13274                                   |     
                                                             |     while (r8 < r0) {
                                                             | label_0:
    0x00013264 mvn r8, 0                                     |         r8 = ~0;
                                                             | label_1:
    0x00013268 mov r0, r8                                    |         r0 = r8;
    0x0001326c sub sp, fp, 0x20                              |         
    0x00013270 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc}      |         
    0x00013274 ldr sb, [r7, 0x44]                            |         sb = *((r7 + 0x44));
    0x00013278 mov r0, sb                                    |         r0 = sb;
    0x0001327c bl 0x10b3c                                    |         strlen (r0);
    0x00013280 mov r3, r6                                    |         r3 = r6;
    0x00013284 mov r2, r5                                    |         r2 = r5;
    0x00013288 mov r1, sb                                    |         r1 = sb;
    0x0001328c add r0, r0, 0x6b                              |         r0 += 0x6b;
    0x00013290 bic r0, r0, 7                                 |         r0 = BIT_MASK (r0, 7);
    0x00013294 sub sp, sp, r0                                |         
    0x00013298 mov r0, sp                                    |         r0 = sp;
    0x0001329c bl 0x10b18                                    |         sprintf (r0, r1, r2);
    0x000132a0 mov r0, sp                                    |         r0 = sp;
    0x000132a4 mov r2, 0x32                                  |         r2 = 0x32;
    0x000132a8 sub r1, fp, 0x58                              |         r1 -= s1;
    0x000132ac bl 0x11838                                    |         fcn_00011838 (r0, r1);
    0x000132b0 mov sp, r8                                    |         
    0x000132b4 subs r8, r0, 0                                |         r8 = r0 - 0;
    0x000132b8 blt 0x13264                                   |         
                                                             |     }
    0x000132bc mov r2, r8                                    |     r2 = r8;
    0x000132c0 ldr r1, [pc, 0x174]                           |     r1 = *(0x13438);
    0x000132c4 sub r0, fp, 0x58                              |     r0 -= s1;
    0x000132c8 bl 0x10a88                                    |     r0 = strncmp (r0, r1, r2);
    0x000132cc cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x000132d0 moveq r3, 4                                   |         r3 = 4;
                                                             |     }
                                                             |     if (r0 != 0) {
    0x000132d4 beq 0x132f4                                   |         
    0x000132d8 mov r2, r8                                    |         r2 = r8;
    0x000132dc ldr r1, [pc, 0x15c]                           |         r1 = "static";
    0x000132e0 sub r0, fp, 0x58                              |         r0 -= s1;
    0x000132e4 bl 0x10a88                                    |         r0 = strncmp (r0, "static", r2);
    0x000132e8 cmp r0, 0                                     |         
                                                             |         if (r0 != 0) {
    0x000132ec bne 0x13414                                   |             goto label_2;
                                                             |         }
    0x000132f0 mov r3, 3                                     |         r3 = 3;
                                                             |     }
    0x000132f4 str r3, [r4, 0x10]                            |     *((r4 + 0x10)) = r3;
    0x000132f8 mov r2, r6                                    |     r2 = r6;
    0x000132fc add r3, r4, 0x14                              |     r3 = r4 + 0x14;
    0x00013300 mov r1, r5                                    |     r1 = r5;
    0x00013304 ldr r0, [r7, 0x4c]                            |     r0 = *((r7 + 0x4c));
    0x00013308 bl 0x117e8                                    |     r0 = fcn_000117e8 (r0, r1);
    0x0001330c cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00013310 bne 0x13264                                   |         goto label_0;
                                                             |     }
    0x00013314 ldr r8, [r7, 0x50]                            |     r8 = *((r7 + 0x50));
    0x00013318 mov sb, sp                                    |     sb = sp;
    0x0001331c mov r0, r8                                    |     r0 = r8;
    0x00013320 bl 0x10b3c                                    |     strlen (r0);
    0x00013324 mov r3, r6                                    |     r3 = r6;
    0x00013328 mov r2, r5                                    |     r2 = r5;
    0x0001332c mov r1, r8                                    |     r1 = r8;
    0x00013330 add r0, r0, 0x6b                              |     r0 += 0x6b;
    0x00013334 bic r0, r0, 7                                 |     r0 = BIT_MASK (r0, 7);
    0x00013338 sub sp, sp, r0                                |     
    0x0001333c mov r0, sp                                    |     r0 = sp;
    0x00013340 bl 0x10b18                                    |     sprintf (r0, r1, r2);
    0x00013344 mov r0, sp                                    |     r0 = sp;
    0x00013348 add r1, r4, 0x18                              |     r1 = r4 + 0x18;
    0x0001334c bl 0x1157c                                    |     fcn_0001157c (r0, r1);
    0x00013350 mov sp, sb                                    |     
    0x00013354 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00013358 bne 0x13264                                   |         goto label_0;
                                                             |     }
    0x0001335c add r3, r4, 0x28                              |     r3 = r4 + 0x28;
    0x00013360 mov r2, r6                                    |     r2 = r6;
    0x00013364 mov r1, r5                                    |     r1 = r5;
    0x00013368 ldr r0, [r7, 0x54]                            |     r0 = *((r7 + 0x54));
    0x0001336c bl 0x117e8                                    |     r0 = fcn_000117e8 (r0, r1);
    0x00013370 cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00013374 bne 0x13264                                   |         goto label_0;
                                                             |     }
    0x00013378 add r3, r4, 0x2c                              |     r3 = r4 + 0x2c;
    0x0001337c mov r2, r6                                    |     r2 = r6;
    0x00013380 mov r1, r5                                    |     r1 = r5;
    0x00013384 ldr r0, [r7, 0x58]                            |     r0 = *((r7 + 0x58));
    0x00013388 bl 0x117e8                                    |     r0 = fcn_000117e8 (r0, r1);
    0x0001338c cmp r0, 0                                     |     
                                                             |     if (r0 != 0) {
    0x00013390 bne 0x13264                                   |         goto label_0;
                                                             |     }
    0x00013394 add r3, r4, 0x30                              |     r3 = r4 + 0x30;
    0x00013398 mov r2, r6                                    |     r2 = r6;
    0x0001339c mov r1, r5                                    |     r1 = r5;
    0x000133a0 ldr r0, [r7, 0x5c]                            |     r0 = *((r7 + 0x5c));
    0x000133a4 bl 0x117e8                                    |     r0 = fcn_000117e8 (r0, r1);
    0x000133a8 subs r8, r0, 0                                |     r8 = r0 - 0;
                                                             |     if (r8 != r0) {
    0x000133ac bne 0x13264                                   |         goto label_0;
                                                             |     }
    0x000133b0 ldr r1, [r4, 0x28]                            |     r1 = *((r4 + 0x28));
    0x000133b4 ldr r0, [r4, 0x2c]                            |     r0 = *((r4 + 0x2c));
    0x000133b8 ldr r7, [r7, 0x60]                            |     r7 = *((r7 + 0x60));
    0x000133bc smull r2, r3, r0, r1                          |     r2:r3 = r0 * r1;
    0x000133c0 mov r0, r7                                    |     r0 = r7;
    0x000133c4 strd r2, r3, [r4, 0x20]                       |     __asm ("strd r2, r3, [r4, 0x20]");
    0x000133c8 bl 0x10b3c                                    |     strlen (r0);
    0x000133cc mov r3, r6                                    |     r3 = r6;
    0x000133d0 mov r2, r5                                    |     r2 = r5;
    0x000133d4 mov r1, r7                                    |     r1 = r7;
    0x000133d8 add r0, r0, 0x6b                              |     r0 += 0x6b;
    0x000133dc bic r0, r0, 7                                 |     r0 = BIT_MASK (r0, 7);
    0x000133e0 sub sp, sp, r0                                |     
    0x000133e4 mov r0, sp                                    |     r0 = sp;
    0x000133e8 bl 0x10b18                                    |     sprintf (r0, r1, r2);
    0x000133ec mov r0, sp                                    |     r0 = sp;
    0x000133f0 mov r2, 0x81                                  |     r2 = 0x81;
    0x000133f4 add r1, r4, 0x34                              |     r1 = r4 + 0x34;
    0x000133f8 bl 0x11838                                    |     fcn_00011838 (r0, r1);
    0x000133fc mov sp, sb                                    |     
    0x00013400 cmp r0, 0                                     |     
                                                             |     if (r0 < 0) {
    0x00013404 blt 0x13264                                   |         goto label_0;
                                                             |     }
    0x00013408 add r4, r4, r0                                |     r4 += r0;
    0x0001340c strb r8, [r4, 0x33]                           |     *((r4 + 0x33)) = r8;
    0x00013410 b 0x13268                                     |     goto label_1;
                                                             | label_2:
    0x00013414 ldr r0, [pc, 0x28]                            |     
    0x00013418 sub r3, fp, 0x58                              |     r3 -= s1;
    0x0001341c ldr r2, [pc, 0x24]                            |     r2 = stderr;
    0x00013420 ldr r1, [pc, 0x24]                            |     r1 = "libubi";
    0x00013424 ldr r0, [r0]                                  |     r0 = "dynamic";
    0x00013428 bl 0x10a64                                    |     r0 = fprintf ("dynamic", "libubi", r2, r3)
    0x0001342c bl 0x10b24                                    |     errno_location ();
    0x00013430 mov r3, 0x16                                  |     r3 = 0x16;
    0x00013434 str r3, [r0]                                  |     *(r0) = r3;
    0x00013438 b 0x13264                                     |     goto label_0;
                                                             | }
    ; assembly                                           | /* r2dec pseudo code output */
                                                         | /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/usr/sbin/ubiattach @ 0x10b90 */
                                                         | #include <stdint.h>
                                                         |  
    ; (fcn) main ()                                      | int32_t main (int32_t argc, char ** argv) {
                                                         |     int32_t var_0h;
                                                         |     int32_t var_4h;
                                                         |     int32_t var_ch;
                                                         |     int32_t var_10h;
                                                         |     int32_t var_14h;
                                                         |     int32_t var_18h;
                                                         |     int32_t var_1ch;
                                                         |     int32_t var_20h;
                                                         |     int32_t var_30h;
                                                         |     int32_t var_38h;
                                                         |     int32_t var_54h;
                                                         |     int32_t var_58h;
                                                         |     int32_t var_60h;
                                                         |     int32_t var_60h_2;
                                                         |     int32_t var_68h;
                                                         |     int32_t var_68h_2;
                                                         |     int32_t var_74h;
                                                         |     int32_t var_90h;
                                                         |     r0 = argc;
                                                         |     r1 = argv;
                                                         |     /* [10] -r-x section size 12308 named .text */
    0x00010b90 push {r4, r5, r6, r7, r8, sb, sl, lr}     |     
    0x00010b94 ldr r8, [pc, 0x4f0]                       |     r8 = *(0x11088);
    0x00010b98 ldr sb, [pc, 0x4f0]                       |     sb = "p:m:d:O:b:hV";
    0x00010b9c ldr r5, [pc, 0x4f0]                       |     r5 = "p:m:d:O:b:hV";
    0x00010ba0 sub sp, sp, 0x90                          |     
    0x00010ba4 mov r6, r0                                |     r6 = r0;
    0x00010ba8 mov r7, r1                                |     r7 = r1;
                                                         | label_0:
    0x00010bac mov sl, 0                                 |     sl = 0;
    0x00010bb0 str sl, [sp]                              |     *(sp) = sl;
    0x00010bb4 mov r3, r8                                |     r3 = r8;
    0x00010bb8 mov r2, sb                                |     r2 = sb;
    0x00010bbc mov r1, r7                                |     r1 = r7;
    0x00010bc0 mov r0, r6                                |     r0 = r6;
    0x00010bc4 str sl, [sp, 0x38]                        |     var_38h = sl;
    0x00010bc8 bl 0x109ec                                |     r0 = getopt_long ();
    0x00010bcc cmn r0, 1                                 |     
    0x00010bd0 mov r4, r0                                |     r4 = r0;
                                                         |     if (r0 == 1) {
    0x00010bd4 beq 0x10dbc                               |         goto label_7;
                                                         |     }
    0x00010bd8 cmp r0, 0x62                              |     
                                                         |     if (r0 == 0x62) {
    0x00010bdc beq 0x10d30                               |         goto label_8;
                                                         |     }
                                                         |     if (r0 <= 0x62) {
    0x00010be0 bgt 0x10c14                               |         
    0x00010be4 cmp r0, 0x4f                              |         
                                                         |         if (r0 == 0x4f) {
    0x00010be8 beq 0x10cec                               |             goto label_9;
                                                         |         }
    0x00010bec cmp r0, 0x56                              |         
                                                         |         if (r0 == 0x56) {
    0x00010bf0 beq 0x10da8                               |             goto label_10;
                                                         |         }
    0x00010bf4 cmp r0, 0x3a                              |         
                                                         |         if (r0 != 0x3a) {
    0x00010bf8 bne 0x10c28                               |             goto label_11;
                                                         |         }
    0x00010bfc ldr r2, [pc, 0x494]                       |         r2 = optarg;
    0x00010c00 ldr r1, [pc, 0x494]                       |         r1 = "ubiattach";
                                                         | label_2:
    0x00010c04 ldr r3, [pc, 0x494]                       |         r3 = "%s: error!: parameter is missing\n";
    0x00010c08 ldr r0, [r3]                              |         r0 = "%s: error!: parameter is missing\n";
    0x00010c0c bl 0x10a64                                |         fprintf ("%s: error!: parameter is missing\n", "ubiattach", r2, "%s: error!: parameter is missing\n")
    0x00010c10 b 0x10ca0                                 |         goto label_12;
                                                         |     }
    0x00010c14 cmp r0, 0x68                              |     
                                                         |     if (r0 == 0x68) {
    0x00010c18 beq 0x10d80                               |         goto label_13;
                                                         |     }
                                                         |     if (r0 > 0x68) {
    0x00010c1c bgt 0x10c3c                               |         goto label_14;
                                                         |     }
    0x00010c20 cmp r0, 0x64                              |     
                                                         |     if (r0 == 0x64) {
    0x00010c24 beq 0x10c5c                               |         goto label_15;
                                                         |     }
                                                         |     do {
                                                         | label_11:
    0x00010c28 ldr r3, [pc, 0x470]                       |         r3 = "%s: error!: parameter is missing\n";
    0x00010c2c ldr r0, [pc, 0x470]                       |         r0 = stderr;
    0x00010c30 ldr r1, [r3]                              |         r1 = "%s: error!: parameter is missing\n";
    0x00010c34 bl 0x10b48                                |         fputs (r0, "%s: error!: parameter is missing\n");
    0x00010c38 b 0x10ca0                                 |         goto label_12;
                                                         | label_14:
    0x00010c3c cmp r0, 0x6d                              |         
                                                         |         if (r0 == 0x6d) {
    0x00010c40 beq 0x10cb0                               |             goto label_16;
                                                         |         }
    0x00010c44 cmp r0, 0x70                              |         
    0x00010c48 bne 0x10c28                               |         
                                                         |     } while (r0 != 0x70);
    0x00010c4c ldr r2, [r5]                              |     r2 = *(r5);
    0x00010c50 ldr r3, [pc, 0x450]                       |     r3 = "Use -h for help\n";
    0x00010c54 str r2, [r3, 0x10]                        |     *((r3 + 0x10)) = r2;
    0x00010c58 b 0x10bac                                 |     goto label_0;
                                                         | label_15:
    0x00010c5c add r1, sp, 0x38                          |     r1 += var_38h;
    0x00010c60 ldr r0, [r5]                              |     r0 = *(r5);
    0x00010c64 bl 0x1123c                                |     fcn_0001123c (r0, r1);
    0x00010c68 ldr r3, [pc, 0x438]                       |     r3 = "Use -h for help\n";
    0x00010c6c str r0, [r3]                              |     *(r3) = r0;
    0x00010c70 ldr r3, [sp, 0x38]                        |     r3 = var_38h;
    0x00010c74 cmp r3, 0                                 |     
                                                         |     if (r3 != 0) {
    0x00010c78 lsreq r0, r0, 0x1f                        |         r0 >>= 0x1f;
                                                         |     }
                                                         |     if (r3 == 0) {
    0x00010c7c movne r0, 1                               |         r0 = 1;
                                                         |     }
    0x00010c80 cmp r0, 0                                 |     
                                                         |     if (r0 == 0) {
    0x00010c84 beq 0x10bac                               |         goto label_0;
                                                         |     }
    0x00010c88 ldr r3, [r5]                              |     r3 = *(r5);
    0x00010c8c ldr r2, [pc, 0x404]                       |     r2 = optarg;
    0x00010c90 ldr r1, [pc, 0x414]                       |     r1 = *(0x110a8);
                                                         | label_1:
    0x00010c94 ldr r0, [pc, 0x404]                       |     
    0x00010c98 ldr r0, [r0]                              |     r0 = "%s: error!: parameter is missing\n";
    0x00010c9c bl 0x10a64                                |     fprintf ("%s: error!: parameter is missing\n", r1, r2, r3)
                                                         | label_12:
    0x00010ca0 mvn r4, 0                                 |     r4 = ~0;
                                                         | label_3:
    0x00010ca4 mov r0, r4                                |     r0 = r4;
    0x00010ca8 add sp, sp, 0x90                          |     
    0x00010cac pop {r4, r5, r6, r7, r8, sb, sl, pc}      |     
                                                         | label_16:
    0x00010cb0 add r1, sp, 0x38                          |     r1 += var_38h;
    0x00010cb4 ldr r0, [r5]                              |     r0 = *(r5);
    0x00010cb8 bl 0x1123c                                |     fcn_0001123c (r0, r1);
    0x00010cbc ldr r3, [pc, 0x3e4]                       |     r3 = "Use -h for help\n";
    0x00010cc0 str r0, [r3, 4]                           |     *((r3 + 4)) = r0;
    0x00010cc4 ldr r3, [sp, 0x38]                        |     r3 = var_38h;
    0x00010cc8 cmp r3, 0                                 |     
                                                         |     if (r3 != 0) {
    0x00010ccc lsreq r0, r0, 0x1f                        |         r0 >>= 0x1f;
                                                         |     }
                                                         |     if (r3 == 0) {
    0x00010cd0 movne r0, 1                               |         r0 = 1;
                                                         |     }
    0x00010cd4 cmp r0, 0                                 |     
                                                         |     if (r0 == 0) {
    0x00010cd8 beq 0x10bac                               |         goto label_0;
                                                         |     }
    0x00010cdc ldr r3, [r5]                              |     r3 = *(r5);
    0x00010ce0 ldr r2, [pc, 0x3b0]                       |     r2 = optarg;
    0x00010ce4 ldr r1, [pc, 0x3c4]                       |     r1 = "%s: error!: bad UBI device number: \"%s\"\n";
    0x00010ce8 b 0x10c94                                 |     goto label_1;
                                                         | label_9:
    0x00010cec add r1, sp, 0x38                          |     r1 += var_38h;
    0x00010cf0 ldr r0, [r5]                              |     r0 = *(r5);
    0x00010cf4 bl 0x1123c                                |     fcn_0001123c (r0, r1);
    0x00010cf8 ldr r3, [pc, 0x3a8]                       |     r3 = "Use -h for help\n";
    0x00010cfc str r0, [r3, 8]                           |     *((r3 + 8)) = r0;
    0x00010d00 ldr r3, [sp, 0x38]                        |     r3 = var_38h;
    0x00010d04 cmp r0, 0                                 |     
                                                         |     if (r0 <= 0) {
    0x00010d08 movgt r0, 0                               |         r0 = 0;
                                                         |     }
                                                         |     if (r0 > 0) {
    0x00010d0c movle r0, 1                               |         r0 = 1;
                                                         |     }
    0x00010d10 cmp r3, 0                                 |     
                                                         |     if (r3 == 0) {
    0x00010d14 movne r0, 1                               |         r0 = 1;
                                                         |     }
    0x00010d18 cmp r0, 0                                 |     
                                                         |     if (r0 == 0) {
    0x00010d1c beq 0x10bac                               |         goto label_0;
                                                         |     }
    0x00010d20 ldr r3, [r5]                              |     r3 = *(r5);
    0x00010d24 ldr r2, [pc, 0x36c]                       |     r2 = optarg;
    0x00010d28 ldr r1, [pc, 0x384]                       |     r1 = "_s:_error_:_bad_MTD_device_number:___s_";
    0x00010d2c b 0x10c94                                 |     goto label_1;
                                                         | label_8:
    0x00010d30 add r1, sp, 0x38                          |     r1 += var_38h;
    0x00010d34 ldr r0, [r5]                              |     r0 = *(r5);
    0x00010d38 bl 0x1123c                                |     fcn_0001123c (r0, r1);
    0x00010d3c ldr r3, [pc, 0x364]                       |     r3 = "Use -h for help\n";
    0x00010d40 str r0, [r3, 0x14]                        |     *((r3 + 0x14)) = r0;
    0x00010d44 ldr r3, [sp, 0x38]                        |     r3 = var_38h;
    0x00010d48 cmp r0, 0x300                             |     
    0x00010d4c cmpls r3, 0                               |     __asm ("cmpls r3, 0");
                                                         |     if (r0 == 0x300) {
    0x00010d50 ldrne r3, [r5]                            |         r3 = *(r5);
                                                         |     }
                                                         |     if (r0 == 0x300) {
    0x00010d54 ldrne r2, [pc, 0x33c]                     |         r2 = "ubiattach";
                                                         |     }
                                                         |     if (r0 != 0x300) {
    0x00010d58 ldrne r1, [pc, 0x358]                     |         r1 = "%s: error!: bad maximum of expected bad blocks (0-768): \"%s\"\n";
                                                         |         goto label_17;
                                                         |     }
                                                         |     if (r0 != 0x300) {
                                                         | label_17:
    0x00010d5c bne 0x10c94                               |         goto label_1;
                                                         |     }
    0x00010d60 cmp r0, 0                                 |     
                                                         |     if (r0 != 0) {
    0x00010d64 bne 0x10bac                               |         goto label_0;
                                                         |     }
    0x00010d68 ldr r3, [pc, 0x330]                       |     r3 = "%s: error!: parameter is missing\n";
    0x00010d6c ldr r2, [pc, 0x324]                       |     r2 = optarg;
    0x00010d70 ldr r1, [pc, 0x344]                       |     r1 = "%s: error!: bad maximum of expected bad blocks (0-768): \"%s\"\n";
    0x00010d74 ldr r0, [r3]                              |     r0 = "%s: error!: parameter is missing\n";
    0x00010d78 bl 0x10a64                                |     fprintf ("%s: error!: parameter is missing\n", "%s: error!: bad maximum of expected bad blocks (0-768): \"%s\"\n", r2, "%s: error!: parameter is missing\n")
    0x00010d7c b 0x10bac                                 |     goto label_0;
                                                         | label_13:
    0x00010d80 ldr r1, [pc, 0x338]                       |     r1 = "_s:_warning_:_the_default_kernel_value_will_be_used_for_maximum_expected_bad_blocks";
    0x00010d84 ldr r0, [pc, 0x338]                       |     r0 = "ubiattach_version_2.1.0___a_tool_to_attach_MTD_device_to_UBI.";
    0x00010d88 bl 0x109c8                                |     printf ("ubiattach_version_2.1.0___a_tool_to_attach_MTD_device_to_UBI.", "_s:_warning_:_the_default_kernel_value_will_be_used_for_maximum_expected_bad_blocks");
    0x00010d8c ldr r1, [pc, 0x334]                       |     r1 = "%s\n\n";
    0x00010d90 ldr r0, [pc, 0x32c]                       |     r0 = "ubiattach_version_2.1.0___a_tool_to_attach_MTD_device_to_UBI.";
    0x00010d94 bl 0x109c8                                |     printf ("ubiattach_version_2.1.0___a_tool_to_attach_MTD_device_to_UBI.", "%s\n\n");
    0x00010d98 ldr r0, [pc, 0x32c]                       |     r0 = "Usage:_ubiattach___UBI_control_device_node_file_name____m__MTD_device_number_____d__UBI_device_number_____p__path_to_device_____mtdn_MTD_device_number______devn_UBI_device_number_____dev_path_path_to_device_____max_beb_per1024_maximum_bad_bloc";
    0x00010d9c bl 0x10a1c                                |     puts ("Usage:_ubiattach___UBI_control_device_node_file_name____m__MTD_device_number_____d__UBI_device_number_____p__path_to_device_____mtdn_MTD_device_number______devn_UBI_device_number_____dev_path_path_to_device_____max_beb_per1024_maximum_bad_bloc");
                                                         |     do {
    0x00010da0 mov r0, sl                                |         r0 = sl;
    0x00010da4 bl 0x10b30                                |         exit (r0);
                                                         | label_10:
    0x00010da8 ldr r2, [pc, 0x320]                       |         r2 = "-d, --devn=<number>   the number to assign to the newly created UBI device\n                      (assigned automatically if this is not specified)\n-p, --dev-path=<path> path to MTD device node to attach\n-m, --mtdn=<number>   MTD device number to attach (alternative method, e.g\n                      if the character device node does not exist)\n-O, --vid-hdr-offset  VID header offset (do not specify this unless you really\n                      know what you are doing, the default should be optimal)\n-b, --max-beb-per1024 maximum expected bad block number per 1024 eraseblock.\n                      The default value is correct for most NAND devices.\n                      Allowed range is 0-768, 0 means the default kernel value.\n-h, --help            print help message\n-V, --version         print program version";
    0x00010dac ldr r1, [pc, 0x2e4]                       |         r1 = optarg;
    0x00010db0 ldr r0, [pc, 0x31c]                       |         r0 = "_.1.0";
    0x00010db4 bl 0x109c8                                |         printf ("_.1.0", r1, "-d, --devn=<number>   the number to assign to the newly created UBI device\n                      (assigned automatically if this is not specified)\n-p, --dev-path=<path> path to MTD device node to attach\n-m, --mtdn=<number>   MTD device number to attach (alternative method, e.g\n                      if the character device node does not exist)\n-O, --vid-hdr-offset  VID header offset (do not specify this unless you really\n                      know what you are doing, the default should be optimal)\n-b, --max-beb-per1024 maximum expected bad block number per 1024 eraseblock.\n                      The default value is correct for most NAND devices.\n                      Allowed range is 0-768, 0 means the default kernel value.\n-h, --help            print help message\n-V, --version         print program version");
    0x00010db8 b 0x10da0                                 |         
                                                         |     } while (1);
                                                         | label_7:
    0x00010dbc ldr r3, [pc, 0x314]                       |     
    0x00010dc0 ldr r3, [r3]                              |     r3 = "_s__mtd_utils___s";
    0x00010dc4 cmp r6, r3                                |     
                                                         |     if (r6 != r3) {
    0x00010dc8 bne 0x10e04                               |         goto label_18;
                                                         |     }
    0x00010dcc ldr r3, [pc, 0x2d4]                       |     r3 = "Use -h for help\n";
    0x00010dd0 ldr r2, [pc, 0x304]                       |     r2 = optind;
                                                         |     do {
    0x00010dd4 str r2, [r3, 0xc]                         |         *((r3 + 0xc)) = r2;
    0x00010dd8 ldr r3, [pc, 0x2c8]                       |         r3 = "Use -h for help\n";
    0x00010ddc ldr r6, [r3, 4]                           |         r6 = *(0x110a8);
    0x00010de0 mov r5, r3                                |         r5 = r3;
    0x00010de4 cmn r6, 1                                 |         
                                                         |         if (r6 != 1) {
    0x00010de8 bne 0x10e30                               |             goto label_19;
                                                         |         }
    0x00010dec ldr r3, [r3, 0x10]                        |         r3 = *((r3 + 0x10));
    0x00010df0 cmp r3, 0                                 |         
                                                         |         if (r3 != 0) {
    0x00010df4 bne 0x10e30                               |             goto label_19;
                                                         |         }
    0x00010df8 ldr r2, [pc, 0x298]                       |         r2 = optarg;
    0x00010dfc ldr r1, [pc, 0x2dc]                       |         r1 = "_dev_ubi_ctrl";
    0x00010e00 b 0x10c04                                 |         goto label_2;
                                                         | label_18:
    0x00010e04 sub r6, r6, 1                             |         r6--;
    0x00010e08 cmp r3, r6                                |         
                                                         |         if (r3 != r6) {
    0x00010e0c ldreq r2, [r7, r3, lsl 2]                 |             offset_0 = r3 << 2;
                                                         |             r2 = *((r7 + offset_0));
                                                         |         }
                                                         |         if (r3 != r6) {
    0x00010e10 ldreq r3, [pc, 0x290]                     |             r3 = *(0x000110a8);
                                                         |         }
    0x00010e14 beq 0x10dd4                               |         
                                                         |     } while (r3 == r6);
    0x00010e18 ldr r3, [pc, 0x280]                       |     r3 = "%s: error!: parameter is missing\n";
    0x00010e1c ldr r2, [pc, 0x274]                       |     r2 = optarg;
    0x00010e20 ldr r1, [pc, 0x2bc]                       |     r1 = "_s:_error_:_MTD_device_to_attach_was_not_specified__use__h_for_help_";
    0x00010e24 ldr r0, [r3]                              |     r0 = "%s: error!: parameter is missing\n";
                                                         |     do {
    0x00010e28 bl 0x10a64                                |         fprintf ("%s: error!: parameter is missing\n", "_s:_error_:_MTD_device_to_attach_was_not_specified__use__h_for_help_", r2, "%s: error!: parameter is missing\n")
    0x00010e2c b 0x10ca4                                 |         goto label_3;
                                                         | label_19:
    0x00010e30 bl 0x11e74                                |         r0 = fcn_00011e74 ();
    0x00010e34 subs r6, r0, 0                            |         r6 = r0 - 0;
                                                         |         if (r6 != r0) {
    0x00010e38 bne 0x10e90                               |             goto label_20;
                                                         |         }
    0x00010e3c bl 0x10b24                                |         errno_location ();
    0x00010e40 ldr r6, [pc, 0x258]                       |         r6 = "%s: error!: parameter is missing\n";
    0x00010e44 ldr r2, [pc, 0x24c]                       |         r2 = optarg;
    0x00010e48 ldr r5, [r0]                              |         r5 = *(r0);
    0x00010e4c ldr r0, [r6]                              |         r0 = "%s: error!: parameter is missing\n";
    0x00010e50 cmp r5, 0                                 |         
                                                         |         if (r5 != 0) {
    0x00010e54 ldreq r1, [pc, 0x28c]                     |             r1 = "%s: error!: UBI is not present in the system\n";
                                                         |         }
    0x00010e58 beq 0x10e28                               |         
                                                         |     } while (r5 == 0);
    0x00010e5c ldr r1, [pc, 0x288]                       |     r1 = "%s: error!: UBI is not present in the system\n";
    0x00010e60 bl 0x10a64                                |     fprintf (r0, "%s: error!: UBI is not present in the system\n")
    0x00010e64 mov r0, r5                                |     r0 = r5;
    0x00010e68 ldr r6, [r6]                              |     r6 = *(r6);
    0x00010e6c bl 0x109d4                                |     strerror (r0);
    0x00010e70 str r5, [sp]                              |     *(sp) = r5;
    0x00010e74 ldr r3, [pc, 0x274]                       |     r3 = "_s:_error_:_cannot_open_libubi";
    0x00010e78 mov r2, 0xb                               |     r2 = 0xb;
    0x00010e7c ldr r1, [pc, 0x270]                       |     r1 = *(0x110f0);
    0x00010e80 str r0, [sp, 4]                           |     var_4h = r0;
    0x00010e84 mov r0, r6                                |     r0 = r6;
    0x00010e88 bl 0x10a64                                |     fprintf (r0, r1, r2, "_s:_error_:_cannot_open_libubi", r4, r5)
    0x00010e8c b 0x10ca4                                 |     goto label_3;
                                                         | label_20:
    0x00010e90 add r1, sp, 0x20                          |     r1 += var_20h;
    0x00010e94 bl 0x12330                                |     r0 = fcn_00012330 (r0, r1);
    0x00010e98 cmp r0, 0                                 |     
                                                         |     if (r0 != 0) {
    0x00010e9c beq 0x10ee4                               |         
    0x00010ea0 bl 0x10b24                                |         errno_location ();
    0x00010ea4 ldr r7, [pc, 0x1f4]                       |         r7 = "%s: error!: parameter is missing\n";
    0x00010ea8 ldr r2, [pc, 0x1e8]                       |         r2 = optarg;
    0x00010eac ldr r1, [pc, 0x244]                       |         r1 = "_serror__d___s_";
    0x00010eb0 ldr r5, [r0]                              |         r5 = *(r0);
                                                         | label_6:
    0x00010eb4 ldr r0, [r7]                              |         r0 = *(r7);
    0x00010eb8 bl 0x10a64                                |         fprintf (r0, "_serror__d___s_", r2, r3, r4, r5)
    0x00010ebc mov r0, r5                                |         r0 = r5;
    0x00010ec0 ldr r7, [r7]                              |         r7 = *(r7);
    0x00010ec4 bl 0x109d4                                |         strerror (r0);
    0x00010ec8 str r5, [sp]                              |         *(sp) = r5;
    0x00010ecc ldr r3, [pc, 0x21c]                       |         r3 = "_s:_error_:_cannot_open_libubi";
    0x00010ed0 mov r2, 0xb                               |         r2 = 0xb;
    0x00010ed4 ldr r1, [pc, 0x218]                       |         r1 = *(0x110f0);
    0x00010ed8 str r0, [sp, 4]                           |         var_4h = r0;
    0x00010edc mov r0, r7                                |         r0 = r7;
    0x00010ee0 b 0x10fa4                                 |         goto label_21;
                                                         |     }
    0x00010ee4 ldr r3, [sp, 0x30]                        |     r3 = var_30h;
    0x00010ee8 cmn r3, 1                                 |     
                                                         |     if (r3 != 1) {
    0x00010eec bne 0x10f10                               |         goto label_22;
                                                         |     }
    0x00010ef0 ldr r3, [pc, 0x1a8]                       |     r3 = "%s: error!: parameter is missing\n";
    0x00010ef4 ldr r2, [pc, 0x19c]                       |     r2 = optarg;
    0x00010ef8 ldr r1, [pc, 0x1fc]                       |     r1 = "_s:_error_:_cannot_get_UBI_information";
    0x00010efc ldr r0, [r3]                              |     r0 = "%s: error!: parameter is missing\n";
    0x00010f00 bl 0x10a64                                |     fprintf ("%s: error!: parameter is missing\n", "_s:_error_:_cannot_get_UBI_information", r2, "%s: error!: parameter is missing\n")
                                                         |     do {
                                                         | label_5:
    0x00010f04 mov r0, r6                                |         r0 = r6;
    0x00010f08 bl 0x11da0                                |         fcn_00011da0 (r0);
    0x00010f0c b 0x10ca4                                 |         goto label_3;
                                                         | label_22:
    0x00010f10 ldr r3, [r5]                              |         r3 = *(r5);
    0x00010f14 add r2, sp, 0xc                           |         r2 += var_ch;
    0x00010f18 str r3, [sp, 0xc]                         |         var_ch = r3;
    0x00010f1c ldr r3, [r5, 4]                           |         r3 = *((r5 + 4));
    0x00010f20 ldr r1, [r5, 0xc]                         |         r1 = *((r5 + 0xc));
    0x00010f24 str r3, [sp, 0x10]                        |         var_10h = r3;
    0x00010f28 ldr r3, [r5, 8]                           |         r3 = *((r5 + 8));
    0x00010f2c mov r0, r6                                |         r0 = r6;
    0x00010f30 str r3, [sp, 0x18]                        |         var_18h = r3;
    0x00010f34 ldr r3, [r5, 0x10]                        |         r3 = *((r5 + 0x10));
    0x00010f38 str r3, [sp, 0x14]                        |         var_14h = r3;
    0x00010f3c ldr r3, [r5, 0x14]                        |         r3 = *((r5 + 0x14));
    0x00010f40 str r3, [sp, 0x1c]                        |         var_1ch = r3;
    0x00010f44 bl 0x12204                                |         r0 = fcn_00012204 (r0);
    0x00010f48 cmp r0, 0                                 |         
                                                         |         if (r0 >= 0) {
    0x00010f4c bge 0x10fbc                               |             goto label_23;
                                                         |         }
    0x00010f50 bl 0x10b24                                |         errno_location ();
    0x00010f54 ldr sl, [r5, 0x10]                        |         sl = *((r5 + 0x10));
    0x00010f58 ldr r8, [pc, 0x140]                       |         r8 = "%s: error!: parameter is missing\n";
    0x00010f5c cmp sl, 0                                 |         
    0x00010f60 ldr sb, [r8]                              |         sb = "%s: error!: parameter is missing\n";
    0x00010f64 ldr r7, [r0]                              |         r7 = *(r0);
                                                         |         if (sl == 0) {
    0x00010f68 beq 0x10fac                               |             goto label_24;
                                                         |         }
    0x00010f6c ldr r2, [pc, 0x124]                       |         r2 = optarg;
    0x00010f70 ldr r1, [pc, 0x188]                       |         r1 = "_s:_error_:_MTD_attach_detach_feature_is_not_supported_by_your_kernel";
    0x00010f74 mov r3, sl                                |         r3 = sl;
                                                         | label_4:
    0x00010f78 mov r0, sb                                |         r0 = sb;
    0x00010f7c bl 0x10a64                                |         fprintf (r0, "_s:_error_:_MTD_attach_detach_feature_is_not_supported_by_your_kernel", r2, r3)
    0x00010f80 mov r0, r7                                |         r0 = r7;
    0x00010f84 ldr r5, [r8]                              |         r5 = *(r8);
    0x00010f88 bl 0x109d4                                |         strerror (r0);
    0x00010f8c ldr r3, [pc, 0x15c]                       |         r3 = "_s:_error_:_cannot_open_libubi";
    0x00010f90 ldr r1, [pc, 0x15c]                       |         r1 = *(0x110f0);
    0x00010f94 mov r2, 0xb                               |         r2 = 0xb;
    0x00010f98 str r7, [sp]                              |         *(sp) = r7;
    0x00010f9c str r0, [sp, 4]                           |         var_4h = r0;
    0x00010fa0 mov r0, r5                                |         r0 = r5;
                                                         | label_21:
    0x00010fa4 bl 0x10a64                                |         fprintf (r0, r1, r2, "_s:_error_:_cannot_open_libubi")
    0x00010fa8 b 0x10f04                                 |         
                                                         |     } while (1);
                                                         | label_24:
    0x00010fac ldr r3, [r5, 4]                           |     r3 = *((r5 + 4));
    0x00010fb0 ldr r2, [pc, 0xe0]                        |     r2 = optarg;
    0x00010fb4 ldr r1, [pc, 0x148]                       |     r1 = "%s: error!: cannot attach \"%s\"\n";
    0x00010fb8 b 0x10f78                                 |     goto label_4;
                                                         | label_23:
    0x00010fbc cmp r0, 1                                 |     
                                                         |     if (r0 == 1) {
    0x00010fc0 bne 0x10ff8                               |         
    0x00010fc4 ldr r0, [pc, 0xd4]                        |         
    0x00010fc8 ldr r3, [r5, 0x14]                        |         r3 = *((r5 + 0x14));
    0x00010fcc ldr r2, [pc, 0xc4]                        |         r2 = optarg;
    0x00010fd0 ldr r1, [pc, 0x130]                       |         r1 = "%s: error!: cannot attach mtd%d\n";
    0x00010fd4 ldr r0, [r0]                              |         r0 = "%s: error!: parameter is missing\n";
    0x00010fd8 bl 0x10a64                                |         fprintf ("%s: error!: parameter is missing\n", "%s: error!: cannot attach mtd%d\n", r2, r3)
    0x00010fdc ldr r1, [pc, 0xb4]                        |         r1 = optarg;
    0x00010fe0 ldr r0, [pc, 0x124]                       |         r0 = "_s:_warning_:_the___max_beb_per1024_d_parameter_was_ignored";
    0x00010fe4 bl 0x109c8                                |         printf ("_s:_warning_:_the___max_beb_per1024_d_parameter_was_ignored", r1);
    0x00010fe8 ldr r1, [pc, 0xa8]                        |         r1 = optarg;
    0x00010fec ldr r0, [pc, 0x11c]                       |         r0 = "_s:_the_UBI_kernel_driver_does_not_support_does_not_allow_changing_the_reserved_PEBs_count";
    0x00010ff0 bl 0x109c8                                |         printf ("_s:_the_UBI_kernel_driver_does_not_support_does_not_allow_changing_the_reserved_PEBs_count", r1);
    0x00010ff4 b 0x10f04                                 |         goto label_5;
                                                         |     }
    0x00010ff8 add r2, sp, 0x38                          |     r2 += var_38h;
    0x00010ffc ldr r1, [sp, 0xc]                         |     r1 = var_ch;
    0x00011000 mov r0, r6                                |     r0 = r6;
    0x00011004 bl 0x12cbc                                |     r0 = fcn_00012cbc (r0, r1);
    0x00011008 subs r5, r0, 0                            |     r5 = r0 - 0;
                                                         |     if (r5 != r0) {
    0x0001100c beq 0x11028                               |         
    0x00011010 bl 0x10b24                                |         errno_location ();
    0x00011014 ldr r7, [pc, 0x84]                        |         r7 = "%s: error!: parameter is missing\n";
    0x00011018 ldr r2, [pc, 0x78]                        |         r2 = optarg;
    0x0001101c ldr r1, [pc, 0xf0]                        |         r1 = "_s:_the_support_was_added_in_kernel_version_3.7__probably_you_are_running_older_kernel_";
    0x00011020 ldr r5, [r0]                              |         r5 = *(r0);
    0x00011024 b 0x10eb4                                 |         goto label_6;
                                                         |     }
    0x00011028 ldr r2, [sp, 0x54]                        |     r2 = var_54h;
    0x0001102c ldr r1, [sp, 0x38]                        |     r1 = var_38h;
    0x00011030 ldr r0, [pc, 0xe0]                        |     r0 = "%s: error!: cannot get information about newly created UBI device\n";
    0x00011034 bl 0x109c8                                |     printf ("%s: error!: cannot get information about newly created UBI device\n", r1, r2);
    0x00011038 mov r2, r5                                |     r2 = r5;
    0x0001103c ldrd r0, r1, [sp, 0x60]                   |     __asm ("ldrd r0, r1, [var_60h]");
    0x00011040 bl 0x113c4                                |     fcn_000113c4 (r0, r1);
    0x00011044 ldr r1, [sp, 0x58]                        |     r1 = var_58h;
    0x00011048 ldr r0, [pc, 0xcc]                        |     r0 = "UBI_device_number__d__total__d_LEBs__";
    0x0001104c bl 0x109c8                                |     printf ("UBI_device_number__d__total__d_LEBs__", r1);
    0x00011050 ldrd r0, r1, [sp, 0x68]                   |     __asm ("ldrd r0, r1, [var_68h]");
    0x00011054 mov r2, r5                                |     r2 = r5;
    0x00011058 bl 0x113c4                                |     fcn_000113c4 (r0, r1);
    0x0001105c ldr r0, [pc, 0xbc]                        |     r0 = "___available__d_LEBs__";
    0x00011060 bl 0x109c8                                |     printf ("___available__d_LEBs__");
    0x00011064 ldr r0, [sp, 0x74]                        |     r0 = var_74h;
    0x00011068 mov r2, 1                                 |     r2 = 1;
    0x0001106c asr r1, r0, 0x1f                          |     r1 = r0 >> 0x1f;
    0x00011070 bl 0x113c4                                |     fcn_000113c4 (r0, r1);
    0x00011074 mov r0, 0xa                               |     r0 = 0xa;
    0x00011078 bl 0x109b0                                |     putchar (r0);
    0x0001107c mov r0, r6                                |     r0 = r6;
    0x00011080 bl 0x11da0                                |     fcn_00011da0 (r0);
    0x00011084 mov r4, r5                                |     r4 = r5;
    0x00011088 b 0x10ca4                                 |     goto label_3;
                                                         | }

[*] Function fprintf used 54 times ubiattach