[#4043] Remove module will not free L1 memory used

Document created by Aaronwu Employee on Aug 28, 2013
Version 1Show Document
  • View in full screen mode

[#4043] Remove module will not free L1 memory used

Submitted By: Meihui Fan

Open Date

2008-04-18 02:15:19     Close Date

2008-05-05 05:11:29

Priority:

Medium     Assignee:

Bryan Wu

Status:

Closed     Fixed In Release:

N/A

Found In Release:

N/A     Release:

svn trunk

Category:

N/A     Board:

Custom

Processor:

ALL     Silicon Revision:

any

Is this bug repeatable?:

Yes     Resolution:

Assigned (Not Start)

Uboot version or rev.:

any     Toolchain version or rev.:

any

App binary format:

N/A     

Summary: Remove module will not free L1 memory used

Details:

 

That is caused by memory access after free.

 

To make it clear, attached patch is my hack to solve this bug.

 

 

Follow-ups

 

--- Bryan Wu                                                 2008-04-22 22:56:24

Thanks a lot, Meihui Fan.

 

Could you please try to pass the checkpatch.pl? Because I saw lots of C++ '//'

comments.

 

-Bryan

 

--- Bryan Wu                                                 2008-04-30 06:06:24

Thanks a lot for this update,

 

Please reconsider following coding style suggestion:

----

         if ((strcmp(".l1.text", secstrings + s->sh_name) == 0) ||

             ((strcmp(".text", secstrings + s->sh_name) == 0)

&&

              (hdr->e_flags & FLG_CODE_IN_L1) && (s->sh_size >

0))) {

            dest = l1_inst_sram_alloc(s->sh_size);

            mod->arch.text_l1 = dest;

             if (dest == NULL) {

                 printk(KERN_ERR

---

 

It is more readable, right?

 

-Bryan

 

--- Bryan Wu                                                 2008-05-05 05:11:29

Applied, Thanks

 

-Bryan

 

 

 

    Files

    Changes

    Commits

    Dependencies

    Duplicates

    Associations

    Tags

 

File Name     File Type     File Size     Posted By

bfin-module-free-l1sram.diff    text/plain    3485    Meihui Fan

bfin-module-free-l1.diff    text/plain    3290    Meihui Fan

Outcomes