From: David Miller <davem@davemloft.net>
To: alex.aring@gmail.com
Cc: alex.bluesman.smirnov@gmail.com, dbaryshkov@gmail.com,
linux-zigbee-devel@lists.sourceforge.net, netdev@vger.kernel.org,
werner@almesberger.net
Subject: Re: [PATCH net-next 01/13] mac802154: at86rf230: add hw flags and merge ops
Date: Tue, 01 Jul 2014 23:14:07 -0700 (PDT) [thread overview]
Message-ID: <20140701.231407.1114227768498633408.davem@davemloft.net> (raw)
In-Reply-To: <1403980431-6201-2-git-send-email-alex.aring@gmail.com>
From: Alexander Aring <alex.aring@gmail.com>
Date: Sat, 28 Jun 2014 20:33:39 +0200
> This patch adds new mac802154 hw flags for transmit power, csma and
> listen before transmit (lbt). These flags indicates that the transceiver
> supports these features. In ieee802154_register_device the callbacks are
> setted by hw flags instead of checking of null.
>
> This patch merges also all at86rf230 operations into one operations structure
> and set the right hw flags for the at86rf230 transceivers.
>
> Signed-off-by: Alexander Aring <alex.aring@gmail.com>
I don't like this, now you've created a situation where a driver crash
is easy to introduce, ie. setting the capability flag but not providing
the operations pointer properly.
You have two choices:
1) Keep the pointer test mechanism
2) Add the flags, but validate the pointer at driver registration time
and fail the register if the pointers for set flags are NULL.
When you fix this up, don't just submit this one patch, resubmit the
entire series.
Thank you.
next prev parent reply other threads:[~2014-07-02 6:14 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-28 18:33 [PATCH net-next 00/13] at86rf230: rework driver implementation Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 02/13] at86rf230: add regmap support Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 05/13] at86rf230: add support for at86rf23x desense Alexander Aring
[not found] ` <1403980431-6201-1-git-send-email-alex.aring-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2014-06-28 18:33 ` [PATCH net-next 01/13] mac802154: at86rf230: add hw flags and merge ops Alexander Aring
2014-07-02 6:14 ` David Miller [this message]
2014-06-28 18:33 ` [PATCH net-next 03/13] at86rf230: rework detect device handling Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 04/13] at86rf230: remove is212 and add driver data Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 06/13] at86rf230: rework transmit and receive handling Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 07/13] at86rf230: move RX_SAFE_MODE setting to hw_init Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 10/13] at86rf230: rework reset to trx_off state change Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 11/13] at86rf230: add timing for channel switch Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 13/13] at86rf230: add new author Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 08/13] at86rf230: rework irq_pol setting Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 09/13] at86rf230: rework state change and start/stop Alexander Aring
2014-06-28 18:33 ` [PATCH net-next 12/13] at86rf230: add sleep cycle timing Alexander Aring
2014-07-01 7:14 ` [Linux-zigbee-devel] [PATCH net-next 00/13] at86rf230: rework driver implementation Thomas Stilwell
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=20140701.231407.1114227768498633408.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=alex.aring@gmail.com \
--cc=alex.bluesman.smirnov@gmail.com \
--cc=dbaryshkov@gmail.com \
--cc=linux-zigbee-devel@lists.sourceforge.net \
--cc=netdev@vger.kernel.org \
--cc=werner@almesberger.net \
/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 NNTP newsgroup(s).