- CLASSERT((int)sizeof(struct lnet_hdr) == 72);
- CLASSERT((int)offsetof(struct lnet_hdr, dest_nid) == 0);
- CLASSERT((int)sizeof(((struct lnet_hdr *)0)->dest_nid) == 8);
- CLASSERT((int)offsetof(struct lnet_hdr, src_nid) == 8);
- CLASSERT((int)sizeof(((struct lnet_hdr *)0)->src_nid) == 8);
- CLASSERT((int)offsetof(struct lnet_hdr, dest_pid) == 16);
- CLASSERT((int)sizeof(((struct lnet_hdr *)0)->dest_pid) == 4);
- CLASSERT((int)offsetof(struct lnet_hdr, src_pid) == 20);
- CLASSERT((int)sizeof(((struct lnet_hdr *)0)->src_pid) == 4);
- CLASSERT((int)offsetof(struct lnet_hdr, type) == 24);
- CLASSERT((int)sizeof(((struct lnet_hdr *)0)->type) == 4);
- CLASSERT((int)offsetof(struct lnet_hdr, payload_length) == 28);
- CLASSERT((int)sizeof(((struct lnet_hdr *)0)->payload_length) == 4);
- CLASSERT((int)offsetof(struct lnet_hdr, msg) == 32);
- CLASSERT((int)sizeof(((struct lnet_hdr *)0)->msg) == 40);
+ BUILD_BUG_ON((int)sizeof(struct lnet_hdr) != 72);
+ BUILD_BUG_ON((int)offsetof(struct lnet_hdr, dest_nid) != 0);
+ BUILD_BUG_ON((int)sizeof(((struct lnet_hdr *)0)->dest_nid) != 8);
+ BUILD_BUG_ON((int)offsetof(struct lnet_hdr, src_nid) != 8);
+ BUILD_BUG_ON((int)sizeof(((struct lnet_hdr *)0)->src_nid) != 8);
+ BUILD_BUG_ON((int)offsetof(struct lnet_hdr, dest_pid) != 16);
+ BUILD_BUG_ON((int)sizeof(((struct lnet_hdr *)0)->dest_pid) != 4);
+ BUILD_BUG_ON((int)offsetof(struct lnet_hdr, src_pid) != 20);
+ BUILD_BUG_ON((int)sizeof(((struct lnet_hdr *)0)->src_pid) != 4);
+ BUILD_BUG_ON((int)offsetof(struct lnet_hdr, type) != 24);
+ BUILD_BUG_ON((int)sizeof(((struct lnet_hdr *)0)->type) != 4);
+ BUILD_BUG_ON((int)offsetof(struct lnet_hdr, payload_length) != 28);
+ BUILD_BUG_ON((int)sizeof(((struct lnet_hdr *)0)->payload_length) != 4);
+ BUILD_BUG_ON((int)offsetof(struct lnet_hdr, msg) != 32);
+ BUILD_BUG_ON((int)sizeof(((struct lnet_hdr *)0)->msg) != 40);