public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Michael Wang <yun.wang@profitbricks.com>
To: Borislav Petkov <bp@alien8.de>
Cc: Joerg Roedel <joro@8bytes.org>,
	Catalin Marinas <catalin.marinas@gmail.com>,
	iommu@lists.linux-foundation.org,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [RFC PATCH v2] iommu/amd: gray the 'irq_remap_table' object for kmemleak
Date: Wed, 2 Dec 2015 15:09:18 +0100	[thread overview]
Message-ID: <565EFB8E.4020600@profitbricks.com> (raw)
In-Reply-To: <20151202135931.GF3783@pd.tnic>



On 12/02/2015 02:59 PM, Borislav Petkov wrote:
> On Wed, Dec 02, 2015 at 02:48:47PM +0100, Michael Wang wrote:
>> I'm not sure why amd-iommu use get_page not kmalloc to initialize the
>> pointer table, but if it's necessary then the conflict will be there,
>> it's not the fault of driver or kmemleak, but the design require them
>> to cooperate with each other.
> 
> So, according to you, we should go and "fix" all callers of
> __get_free_pages() to make kmemleak happy. Then when the next new tool
> comes along, we should "fix" another kernel API just so that the tools
> are happy.

That's the way we have to detect leak, no driver could get rid of
the possibility of memory leaking, so it should respect the rule to
help others locating the problem, if a driver full of false report then
most likely folks will gradually lost interests on help fix leaking
problem for it.

> 
> Bzzt. Wrong!
> 
> The tools should work without sprinkling their code everywhere. Driver
> etc developers don't need to care about what tool they make happy or
> not. Tools' hooks should be hidden in macro magic so that developers
> don't care.

This tool will help improve the kernel, AFAIK it's already made it's
best, if you got any idea on how to make it even better that would be
great, but at this moment, it still need few of care :-P

Regards,
Michael Wang

> 

  reply	other threads:[~2015-12-02 14:09 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-20 11:09 [RFC PATCH] iommu/amd: make kmemleak ignore the 'irq_remap_table' object Michael Wang
2015-11-20 11:33 ` [RFC PATCH v2] iommu/amd: gray the 'irq_remap_table' object for kmemleak Michael Wang
2015-11-20 12:31   ` Michael Wang
2015-11-25 11:14   ` Michael Wang
2015-11-25 15:08   ` Joerg Roedel
2015-11-25 15:14     ` Michael Wang
2015-12-02 10:37       ` Michael Wang
2015-12-02 10:52         ` Catalin Marinas
2015-12-02 10:56           ` Michael Wang
2015-12-02 11:31             ` Catalin Marinas
2015-12-02 11:38               ` Michael Wang
2015-12-02 11:51                 ` Joerg Roedel
2015-12-02 12:31                   ` Michael Wang
2015-12-02 12:53                     ` Borislav Petkov
2015-12-02 13:01                       ` Michael Wang
2015-12-02 13:13                         ` Borislav Petkov
2015-12-02 13:18                           ` Michael Wang
2015-12-02 13:40                             ` Borislav Petkov
2015-12-02 13:48                               ` Michael Wang
2015-12-02 13:59                                 ` Borislav Petkov
2015-12-02 14:09                                   ` Michael Wang [this message]
2015-12-02 14:13                                     ` Borislav Petkov
2015-12-02 14:21                                       ` Michael Wang
2015-12-02 17:36                                   ` Catalin Marinas
2015-12-02 18:40                                     ` Borislav Petkov
2015-12-03  8:47                                     ` Michael Wang
2015-12-02 12:56                     ` Joerg Roedel
2015-12-02 13:07                       ` Michael Wang
2015-12-02 11:17           ` Joerg Roedel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=565EFB8E.4020600@profitbricks.com \
    --to=yun.wang@profitbricks.com \
    --cc=bp@alien8.de \
    --cc=catalin.marinas@gmail.com \
    --cc=iommu@lists.linux-foundation.org \
    --cc=joro@8bytes.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox