public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Masahiro Yamada
	<yamada.masahiro-uWyLwvC0a2jby3iVrkZq2A@public.gmane.org>
Cc: David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>,
	Linux Kernel Mailing List
	<linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	Thomas Gleixner <tglx-hfZtesqFncYOwBW4kG4KsQ@public.gmane.org>,
	Andrew Morton
	<akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org>,
	Ian Abbott <abbotti-GUHe90Wt2aFaa/9Udqfwiw@public.gmane.org>,
	Ingo Molnar <mingo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	Linus Torvalds
	<torvalds-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org>,
	linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	yishaih-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org,
	tariqt-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org,
	netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 10/12] net/mlx4: replace <linux/radix-tree.h> with <linux/radix-tree-root.h>
Date: Mon, 9 Oct 2017 09:10:30 +0300	[thread overview]
Message-ID: <20171009061030.GI25829@mtr-leonro.local> (raw)
In-Reply-To: <CAK7LNARAhAaO+YjqXyBbi=-udCu8zzGnLMsoVNdkSXtXPuMKsA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 1763 bytes --]

On Mon, Oct 09, 2017 at 02:56:56PM +0900, Masahiro Yamada wrote:
> 2017-10-09 3:55 GMT+09:00 Leon Romanovsky <leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>:
> > On Mon, Oct 09, 2017 at 02:29:15AM +0900, Masahiro Yamada wrote:
> >> 2017-10-09 2:00 GMT+09:00 David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>:
> >> > From: Masahiro Yamada <yamada.masahiro-uWyLwvC0a2jby3iVrkZq2A@public.gmane.org>
> >> > Date: Mon,  9 Oct 2017 01:10:11 +0900
> >> >
> >> >> The headers
> >> >>  - include/linux/mlx4/device.h
> >> >>  - drivers/net/ethernet/mellanox/mlx4/mlx4.h
> >> >> require the definition of struct radix_tree_root, but do not need to
> >> >> know anything about other radix tree stuff.
> >> >>
> >> >> Include <linux/radix-tree-root.h> instead of <linux/radix-tree.h> to
> >> >> reduce the header dependency.
> >> >>
> >> >> While we are here, let's add missing <linux/radix-tree.h> where
> >> >> radix tree accessors are used.
> >> >>
> >> >> Signed-off-by: Masahiro Yamada <yamada.masahiro-uWyLwvC0a2jby3iVrkZq2A@public.gmane.org>
> >> >
> >> > Honestly this makes things more complicated.
> >>
> >>
> >> The idea is simple; include necessary headers explicitly.
> >>
> >> Putting everything into one common header
> >> means most of C files are forced to parse unnecessary headers.
> >
> > It is neglected, only first caller will actually parse that header file,
> > other callers will check the #ifndef pragma without need to reparse the
> > whole file.
> >
>
>
> You completely neglected the point of the discussion.
>
> I am trying to not include unnecessary headers at all.
>

I understand it and have no issues with that, just have hard time to justify for
myself any benefit of doing it.

Thanks

>
>
>
> --
> Best Regards
> Masahiro Yamada

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  parent reply	other threads:[~2017-10-09  6:10 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-08 16:10 [PATCH 00/12] radix-tree: split out struct radix_tree_root out to <linux/radix-tree-root.h> Masahiro Yamada
2017-10-08 16:10 ` [PATCH 10/12] net/mlx4: replace <linux/radix-tree.h> with <linux/radix-tree-root.h> Masahiro Yamada
2017-10-08 17:00   ` David Miller
2017-10-08 17:29     ` Masahiro Yamada
2017-10-08 17:32       ` Joe Perches
     [not found]         ` <1507483942.11434.4.camel-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org>
2017-10-09  5:55           ` Masahiro Yamada
2017-10-09 12:02         ` Masahiro Yamada
2017-10-08 18:55       ` Leon Romanovsky
2017-10-09  5:56         ` Masahiro Yamada
     [not found]           ` <CAK7LNARAhAaO+YjqXyBbi=-udCu8zzGnLMsoVNdkSXtXPuMKsA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-10-09  6:10             ` Leon Romanovsky [this message]
2017-10-08 16:10 ` [PATCH 11/12] net/mlx5: " Masahiro Yamada
2017-10-08 17:00   ` David Miller
     [not found] ` <1507479013-5207-1-git-send-email-yamada.masahiro-uWyLwvC0a2jby3iVrkZq2A@public.gmane.org>
2017-10-08 18:52   ` [PATCH 00/12] radix-tree: split out struct radix_tree_root out to <linux/radix-tree-root.h> Leon Romanovsky
2017-10-09  5:58     ` Masahiro Yamada
2017-10-09  6:05       ` Leon Romanovsky
2017-10-10 12:18 ` Matthew Wilcox
2017-10-10 12:56   ` Masahiro Yamada
2017-10-10 13:20     ` Matthew Wilcox

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=20171009061030.GI25829@mtr-leonro.local \
    --to=leon-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
    --cc=abbotti-GUHe90Wt2aFaa/9Udqfwiw@public.gmane.org \
    --cc=akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org \
    --cc=davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mingo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=tariqt-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
    --cc=tglx-hfZtesqFncYOwBW4kG4KsQ@public.gmane.org \
    --cc=torvalds-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org \
    --cc=yamada.masahiro-uWyLwvC0a2jby3iVrkZq2A@public.gmane.org \
    --cc=yishaih-VPRAkNaXOzVWk0Htik3J/w@public.gmane.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