提交 1791f539 编写于 作者: J Jesper Nilsson

CRIS v32: Minor changes to avoid errors in asm-cris/arch-v32/hwregs/reg_rdwr.h

- Add ifdef around macros to read and write hardware registers
- Add parens around REG_READ expression to avoid possible precedence errors.
- Remove useless CVS id tag.
上级 b8ed6b4d
/* $Id: reg_rdwr.h,v 1.6 2005/04/24 18:30:58 starvik Exp $
*
/*
* Read/write register macros used by *_defs.h
*/
#ifndef reg_rdwr_h
#define reg_rdwr_h
#ifndef REG_READ
#define REG_READ(type, addr) (*((volatile type *) (addr)))
#endif
#define REG_READ(type, addr) *((volatile type *) (addr))
#ifndef REG_WRITE
#define REG_WRITE(type, addr, val) \
do { *((volatile type *) (addr)) = (val); } while(0)
#endif
#endif
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册