Re: [PATCH 2/2] sata_mv: remove iounmap in mv_platform_remove

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



saeed bishara wrote:
 > this will fix crash bug when doing rmmod to the driver, this is because the
 > port_stop function get called later and it could access the device's registers.
 >

 Where does the iounmap() now get done instead of that place?

nowhere, the /proc/iomem still shows that sata_mv uses io mempry after
the rrmod, but when I re-load the driver, I can see it reuses the same
io address range. so it doesn't waste io mem  resources.
..

Mmm.. sounds like a bug to me.  Possibly two bugs:

1. the ioremap() should fail if the range is already mapped, and
2. we should free the resources on module unload.

I suppose this would be mostly automatic if the code simply
were to use devm_ioremap() instead of ioremap().

Cheers
-
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux