Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1713065 > unrolled thread

Re: [PATCH] IB/core: fix memory leak on ah on error return path

Started byDoug Ledford <dledford@redhat.com>
First post2017-08-16 17:40 +0200
Last post2017-08-16 17:40 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH] IB/core: fix memory leak on ah on error return path Doug Ledford <dledford@redhat.com> - 2017-08-16 17:40 +0200

#1713065 — Re: [PATCH] IB/core: fix memory leak on ah on error return path

FromDoug Ledford <dledford@redhat.com>
Date2017-08-16 17:40 +0200
SubjectRe: [PATCH] IB/core: fix memory leak on ah on error return path
Message-ID<uf8Ai-mw-5@gated-at.bofh.it>
On Tue, 2017-08-08 at 19:48 +0000, Parav Pandit wrote:
> Hi,
> 
> I need to top post because comments are unrelated to past discussion.
> 
> rdma_ah_retrieve_dmac() can never fail for RoCE as its returning
> pointer from structure ah_attr.
> Provider driver doesn't need to check for null pointer as ib/core
> would never call provider if it's not RoCE provider.
> So this memory leak only exist in theory.
> 
> When its null, driver should WARN_ON/BUG_ON in extreme case, but
> that's not necessary either.
> 
> I have patch is progress under internal review that does nice small
> cleanup in many provider drivers that eliminates the check
> completely.
> Waiting for Moni to finish the review.

This sounds like a nice patch to push into for-next, but in the
meantime I took the V2 of this patch as it silences a checker warning.

-- 
Doug Ledford <dledford@redhat.com>
    GPG KeyID: B826A3330E572FDD
    Key fingerprint = AE6B 1BDA 122B 23B4 265B  1274 B826 A333 0E57 2FDD

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web