lkml.org 
[lkml]   [2005]   [Feb]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2.6.11-rc4-mm1] connector: Add a fork connector
Guillaume Thouvenin <guillaume.thouvenin@bull.net> wrote:
>
> +#define CN_FORK_MSG_SIZE sizeof(struct cn_msg) + CN_FORK_INFO_SIZE

This really should be parenthesized.

> +spinlock_t fork_cn_lock = SPIN_LOCK_UNLOCKED;

This should have static scope, and could be local to fork_connector().

Please use DEFINE_SPINLOCK(). (There's a reason for this, but I forget
what it was).

> +static inline void fork_connector(pid_t parent, pid_t child)
> +{
> + static const struct cb_id fork_id = { CN_IDX_FORK, CN_VAL_FORK };

It's a bit lame to have two copies of this. Maybe have just a single copy,
declare it in connector.h?

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:10    [W:0.144 / U:0.500 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site