public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: Marcel Holtmann <marcel@holtmann.org>
To: David Herrmann <dh.herrmann@googlemail.com>
Cc: linux-bluetooth@vger.kernel.org, padovan@profusion.mobi
Subject: Re: [PATCH] Bluetooth: Remove redundant hdev->parent field
Date: Fri, 09 Mar 2012 09:12:41 -0800	[thread overview]
Message-ID: <1331313161.14217.17.camel@aeonflux> (raw)
In-Reply-To: <1331304822-426-1-git-send-email-dh.herrmann@googlemail.com>

Hi David,

> We initialize the "struct device" in hci_alloc_dev() for a long time now
> so we can access hdev->dev.parent directly. Hence, we can drop the
> temporary field hdev->parent which is used in no other place than
> hci_add_sysfs().
> 
> SET_HCIDEV_DEV() is never called after registering a device by the drivers
> so we do not overwrite internal device-state. Furthermore, hdev->dev is
> initialized to 0 by kzalloc() inside hci_alloc_dev() so the default
> behavior with dev.parent = NULL is kept.
> 
> Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
> ---
>  drivers/bluetooth/hci_ldisc.c    |    2 +-
>  include/net/bluetooth/hci_core.h |    3 +--
>  net/bluetooth/hci_sysfs.c        |    1 -
>  3 files changed, 2 insertions(+), 4 deletions(-)

Acked-by: Marcel Holtmann <marcel@holtmann.org>

Regards

Marcel



  reply	other threads:[~2012-03-09 17:12 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-09 14:53 [PATCH] Bluetooth: Remove redundant hdev->parent field David Herrmann
2012-03-09 17:12 ` Marcel Holtmann [this message]
2012-03-16 15:26 ` Johan Hedberg

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=1331313161.14217.17.camel@aeonflux \
    --to=marcel@holtmann.org \
    --cc=dh.herrmann@googlemail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=padovan@profusion.mobi \
    /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