Re: [PATCH v2 1/8] core: Convert the pincode callback to an interable list.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Alex,

On Fri, Apr 12, 2013, Alex Deymo wrote:
> The current pincode callback list on the adapter keeps track of all the
> pincode callbacks registered by a plugin for that adapter and calls each
> one until one provides a pincode for the current bonding. This mechanism
> forgets about what happened with previous bonding attempts and pushes the
> status track to the plugin side.
> 
> This patch creates an iterator struct (struct pincb_iter) that keeps track
> of the last function called and the number of times called. This will
> allow to provide more information about the bonding status to the pincode
> callback.
> ---
>  src/adapter.c | 52 ++++++++++++++++++++++++++++++++++++++++++++--------
>  src/adapter.h |  4 ++++
>  src/device.c  | 13 +++++++++++++
>  src/device.h  |  1 +
>  4 files changed, 62 insertions(+), 8 deletions(-)

This patch doesn't pass basic coding style checks:

Applying: core: Convert the pincode callback to an interable list.
ERROR:OPEN_BRACE: open brace '{' following function declarations go on the next line
#24: FILE: src/adapter.c:4778:
+struct pincb_iter *pincb_iter_new(struct btd_adapter *adapter) {

ERROR:OPEN_BRACE: open brace '{' following function declarations go on the next line
#33: FILE: src/adapter.c:4787:
+void pincb_iter_free(struct pincb_iter *iter) {

ERROR:OPEN_BRACE: open brace '{' following function declarations go on the next line
#37: FILE: src/adapter.c:4791:
+gboolean pincb_iter_end(struct pincb_iter *iter) {

ERROR:OPEN_BRACE: open brace '{' following function declarations go on the next line
#144: FILE: src/device.c:3749:
+struct pincb_iter *device_bonding_iter(struct btd_device *device) {

Please fix those (and in other patches too if you have them). FWIW, I'm
using the following in my .git/hooks/pre-{applypatch,commit}:

git diff --cached | ~/src/linux/scripts/checkpatch.pl --no-signoff --ignore INITIALISED_STATIC,NEW_TYPEDEFS,VOLATILE,PARENTHESIS_ALIGNMENT --show-types --mailback -

The above assumes you've got a recent kernel source directory in ~/src/linux.

Johan
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux