Ignore:
Timestamp:
Apr 16, 2017, 3:07:01 PM (3 months ago)
Author:
brainslayer
Message:

update

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/linux/universal/linux-3.18/drivers/mtd/maps/pmcmsp-flash.c

    r25370 r31869  
    140140
    141141                msp_maps[i].bankwidth = 1;
    142                 msp_maps[i].name = kmalloc(7, GFP_KERNEL);
     142                msp_maps[i].name = kstrndup(flash_name, 7, GFP_KERNEL);
    143143                if (!msp_maps[i].name) {
    144144                        iounmap(msp_maps[i].virt);
     
    146146                        goto cleanup_loop;
    147147                }
    148 
    149                 msp_maps[i].name = strncpy(msp_maps[i].name, flash_name, 7);
    150148
    151149                for (j = 0; j < pcnt; j++) {
Note: See TracChangeset for help on using the changeset viewer.