- From: Robin Cornelius <robin.cornelius_at_hirst-magnetics.com>
- Date: Tue, 23 Oct 2007 13:01:48 +0100
Ian Abbott wrote: >> based machine. >> > > Yes, "unsigned int" is always 32-bits on Linux: > > unsigned char: 8 bits > unsigned short: 16 bits > unsigned int: 32 bits > unsigned long: 32 bits or 64 bits, depending on architecture, but same > size as a pointer. > > The above is not universally true, but is true for Linux (until some > weird architecture needs to be supported!). > > To be absolutely sure there are types defined in <linux/types.h> for _int8 _int16 _int32 _int64 Microsoft have some similar prototypes too in there C. if you are in the kernel you have :- u8,u16,u32,s8,s16,s32 etc No getting it wrong with those! Any new ARCH must implement those prototypes Robin -- Dr Robin Cornelius Design Engineer Hirst Magnetic Instruments Ltd (UK Magnetics Society management committee member) Tel: +44 (0) 1326 372734 www.hirst-magnetics.com Fax: +44 (0) 1326 378069 www.gaussmeter.co.uk Tesla House, Tregoniggie Industrial Estate Falmouth, Cornwall, TR11 4SN, U.K. Reg No: 1564814 England VAT Registered: GB730 0277 74
Received on 2007-10-23Z11:01:48