[lkml]   [2006]   [May]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 3/6] myri10ge - Driver header files
A few quick obvious comments:

> +#ifdef MYRI10GE_MCP
> +typedef signed char int8_t;
> +typedef signed short int16_t;
> +typedef signed int int32_t;
> +typedef signed long long int64_t;
> +typedef unsigned char uint8_t;
> +typedef unsigned short uint16_t;
> +typedef unsigned int uint32_t;
> +typedef unsigned long long uint64_t;
> +#endif

What's this doing? If you must use uintXX_t types the kernel already
has them. Although it would be nicer to use u8, u16, etc.

> +/* 8 Bytes */
> +typedef struct
> +{
> + uint32_t high;
> + uint32_t low;
> +} mcp_dma_addr_t;

All of these typedefs are unnecessary. In the kernel it's strongly
preferred to just do

struct mcp_dma_addr {
u32 high;
u32 low;

and then use "struct mcp_dma_addr" instead of "mcp_dma_addr_t".

Similarly for enums. Just use "enum whatever" instead of "whatever_t".

BTW, indentation is busted in these headers too (two spaces instead of a tab).

- R.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2006-05-11 00:00    [W:0.171 / U:9.368 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site