($INBOX_DIR/description missing)
 help / color / mirror / Atom feed
From: Andrew Zaborowski <andrew.zaborowski at intel.com>
To: ell at lists.01.org
Subject: Re: [PATCH 07/17] netconfig: Use an internal rtnl socket for l_netconfig_apply_rtnl
Date: Thu, 19 May 2022 23:38:59 +0200	[thread overview]
Message-ID: <CAOq732LhennE6fXjZf2xoWBRtpeegpfZZBKGwij9=28zek42sg@mail.gmail.com> (raw)
In-Reply-To: 522021c7-6b24-674c-f139-832624217ff0@gmail.com

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

On Thu, 19 May 2022 at 23:28, Denis Kenzior <denkenz(a)gmail.com> wrote:
> On 5/19/22 15:53, Andrew Zaborowski wrote:
> > On Thu, 19 May 2022 at 22:28, Denis Kenzior <denkenz(a)gmail.com> wrote:
> >>> Makes sense.  How about using a global rtnl object for all of the
> >>> l_netconfig objects?  Do you still prefer that it be passed from
> >>> outside?
> >>
> >> I have no real preference on whether it is passed in from the outside vs not.
> >> But, there's another thing to consider here.  Today the call to l_foo_set_rtnl
> >> is used determine whether the dhcp/icmp/dhcp6 object should set everything up
> >> directly vs letting the outside layer do this.  With l_netconfig I don't think
> >> this is a problem per se, but you should consider the other classes when you
> >> design this.
> >
> > Right but with l_netconfig you make this choice by either calling
> > l_netconfig_apply_rtnl or not, and you shouldn't call l_foo_set_rtnl
> > on the underlying dhcp/icmp objects.
> >
>
> Sure, but are you assuming we will not have any further classes using rtnl
> besides netconfig?
>
> >>
> >> We can start by trying to come up with a nice ell API for obtaining the
> >> singleton rtnl object and go from there.
> >
> > The global rtnl object I meant is to be used only by l_netconfig
> > instances so there's no need for a getter, or I'm misunderstanding
> > what you're saying.
> >
>
> We use rtnl all over the place in iwd, like netdev, p2p, ap, etc.  All these +
> netconfig should share the same one.

That's different than what I did in patch 11/17 but it would work.
I'll put it in rtnl.c then, with a _get() and a _put() since we have
no generic refcounting for l_netlink.

Best refards

             reply	other threads:[~2022-05-19 21:38 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-19 21:38 Andrew Zaborowski [this message]
  -- strict thread matches above, loose matches on Subject: below --
2022-05-19 21:28 [PATCH 07/17] netconfig: Use an internal rtnl socket for l_netconfig_apply_rtnl Denis Kenzior
2022-05-19 20:53 Andrew Zaborowski
2022-05-19 20:28 Denis Kenzior
2022-05-19 11:52 Andrew Zaborowski
2022-05-18 18:58 Denis Kenzior
2022-05-13 22:47 Andrew Zaborowski
2022-05-13 14:55 Andrew Zaborowski

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='CAOq732LhennE6fXjZf2xoWBRtpeegpfZZBKGwij9=28zek42sg@mail.gmail.com' \
    --to=ell@lists.linux.dev \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).