[sheepdog] [PATCH] sheepdog proto: avoid using stdint.h macros, so sbd can build.

Hitoshi Mitake mitake.hitoshi at lab.ntt.co.jp
Tue Jan 20 03:48:01 CET 2015


At Tue, 20 Jan 2015 10:26:33 +0800,
hujianyang wrote:
> 
> On 2015/1/20 10:19, Hitoshi Mitake wrote:
> > At Mon, 19 Jan 2015 12:39:44 -0800,
> > Alexander Guy wrote:
> >>
> >> The Linux kernel headers don't have the *_C suffix macros, so
> >> they can't be used in a header file shared between sheepdog userspace
> >> and the sbd kernel module.
> >>
> >> Signed-off-by: Alexander Guy <alexander at andern.org>
> >> ---
> >>  include/sheepdog_proto.h | 2 +-
> >>  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > Applied, thanks.
> > Hitoshi
> > 
> >>
> >> diff --git a/include/sheepdog_proto.h b/include/sheepdog_proto.h
> >> index 3910bd5..0599ece 100644
> >> --- a/include/sheepdog_proto.h
> >> +++ b/include/sheepdog_proto.h
> >> @@ -493,7 +493,7 @@ static inline bool is_data_obj(uint64_t oid)
> >>  static inline size_t count_data_objs(const struct sd_inode *inode)
> >>  {
> >>  	return DIV_ROUND_UP(inode->vdi_size,
> >> -			    (UINT32_C(1) << inode->block_size_shift));
> >> +			    (1UL << inode->block_size_shift));
> >>  }
> >>  
> >>  static inline size_t get_objsize(uint64_t oid, uint32_t object_size)
> >> -- 
> >> 2.1.4
> >>
> >> -- 
> >> sheepdog mailing list
> >> sheepdog at lists.wpkg.org
> >> https://lists.wpkg.org/mailman/listinfo/sheepdog
> 
> Hi Hitoshi,
> 
> Actually, another change is needed in sbd module.
> 
>   replace "strict_strtoul" by "kstroul"
> 
> See the mail I sent to you yesterday.
> 
> I guess you miss that mail~

Hi Hu,

OK, I'll post a patch for it.

Thanks,
Hitoshi

> 
> Thanks,
> Hu
> 
> -- 
> sheepdog mailing list
> sheepdog at lists.wpkg.org
> https://lists.wpkg.org/mailman/listinfo/sheepdog



More information about the sheepdog mailing list