lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 3 Nov 2010 12:59:59 -0400
From:	Stephen Hemminger <shemminger@...tta.com>
To:	Chris Metcalf <cmetcalf@...era.com>
Cc:	linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [PATCH] drivers/net/tile/: on-chip network drivers for the tile
 architecture

On Mon, 1 Nov 2010 17:00:37 -0400
Chris Metcalf <cmetcalf@...era.com> wrote:

> This change adds the first network driver for the tile architecture,
> supporting the on-chip XGBE and GBE shims.
> 
> The infrastructure is present for the TILE-Gx networking drivers (another
> three source files in the new directory) but for now the the actual
> tilegx sources are waiting on releasing hardware to initial customers.
> 
> Note that arch/tile/include/hv/* are "upstream" headers from the
> Tilera hypervisor and will probably benefit less from LKML review.
> 

> Signed-off-by: Chris Metcalf <cmetcalf@...era.com>
> +typedef struct {
> +  /** Byte offset of the next notify packet to be written: zero for the first
> +   *  packet on the queue, sizeof (netio_pkt_t) for the second packet on the
> +   *  queue, etc. */
> +  volatile uint32_t __packet_write;
> +
> +  /** Offset of the packet after the last valid packet (i.e., when any
> +   *  pointer is incremented to this value, it wraps back to zero). */
> +  uint32_t __last_packet_plus_one;
> +}
> +__netio_packet_queue_t;

1. MUST not use volatile, see volatile-considered-harmful.txt
2. SHOULD use __u32 rather than uint32_t in kernel structures
3. MUST not introduce typedef's; use structures
4. SHOULD use proper kernel implementation

If you use scripts/checkpatch.pl it will tell you about these.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ