Re: Kernelnewbies Digest, Vol 40, Issue 16

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

 



Ok they are gone part of the order did not come in. Though it's working and the inside is setup very pretty. You can adjust the stones and sand there is extra or both on the bed.

---
Please excuse If this message is overly terse. It is because it is being sent on my iPad.

> On Mar 10, 2014, at 12:00 PM, kernelnewbies-request@xxxxxxxxxxxxxxxxx wrote:
> 
> Send Kernelnewbies mailing list submissions to
>    kernelnewbies@xxxxxxxxxxxxxxxxx
> 
> To subscribe or unsubscribe via the World Wide Web, visit
>    http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> or, via email, send a message with subject or body 'help' to
>    kernelnewbies-request@xxxxxxxxxxxxxxxxx
> 
> You can reach the person managing the list at
>    kernelnewbies-owner@xxxxxxxxxxxxxxxxx
> 
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Kernelnewbies digest..."
> 
> 
> Today's Topics:
> 
>   1. How to check if my kernel driver is leaking memory (m silverstri)
>   2. Re: How to check if my kernel driver is leaking memory
>      (Valdis.Kletnieks@xxxxxx)
> 
> 
> ----------------------------------------------------------------------
> 
> Message: 1
> Date: Sun, 9 Mar 2014 22:14:24 -0700
> From: m silverstri <michael.j.silverstri@xxxxxxxxx>
> Subject: How to check if my kernel driver is leaking memory
> To: kernelnewbies <kernelnewbies@xxxxxxxxxxxxxxxxx>
> Message-ID:
>    <CABMudhTc8c9hBt8QaS1TWyc0vnCY1YWTk3i2xyyVo6moMy-c3g@xxxxxxxxxxxxxx>
> Content-Type: text/plain; charset=ISO-8859-1
> 
> Hi,
> 
> I am developing a kernel driver. What should I test to make sure my
> kernel driver is not leaking memory?
> 1. under normal operation (when applications open and close my driver properly)
> 2. in error situation (when application open my driver and then it
> crashes without close my driver property)
> 
> How can I find out the memory usage used by my driver? so that I can
> monitor it over time.
> 
> Thank you.
> 
> 
> 
> ------------------------------
> 
> Message: 2
> Date: Mon, 10 Mar 2014 09:58:39 -0400
> From: Valdis.Kletnieks@xxxxxx
> Subject: Re: How to check if my kernel driver is leaking memory
> To: m silverstri <michael.j.silverstri@xxxxxxxxx>
> Cc: kernelnewbies <kernelnewbies@xxxxxxxxxxxxxxxxx>
> Message-ID: <167370.1394459919@xxxxxxxxxxxxxxxxxxxxxxx>
> Content-Type: text/plain; charset="us-ascii"
> 
> On Sun, 09 Mar 2014 22:14:24 -0700, m silverstri said:
> 
>> I am developing a kernel driver. What should I test to make sure my
>> kernel driver is not leaking memory?
> 
> 1) The brute force method - just add lots of printk's that have
> "allocating 25-byte frobozz struct" and "freeing 25-byte frobozz struct"
> and make sure they match up.
> 
> 2) kmemleak.
> 
>> 1. under normal operation (when applications open and close my driver properly)
>> 2. in error situation (when application open my driver and then it
>> crashes without close my driver property)
> 
> Case (2) shouldn't happen, as even if a program crashes the kernel *should*
> be invoking the cleanup of open files at process termination.
> 
> A more common cause of memory leaks is for an open() or read/write/ioctl()
> path to allocate N chunks of memory, hit an error, and return after having
> cleaned up only N-1 of the chunks.  This is part of why most kernel code
> uses a 'goto error' structure with only one return; at the end of the function.
> 
> -------------- next part --------------
> A non-text attachment was scrubbed...
> Name: not available
> Type: application/pgp-signature
> Size: 848 bytes
> Desc: not available
> Url : http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140310/3ae80b6f/attachment-0001.bin 
> 
> ------------------------------
> 
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies@xxxxxxxxxxxxxxxxx
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> 
> 
> End of Kernelnewbies Digest, Vol 40, Issue 16
> *********************************************

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies




[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux