Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP2:GA
libmlx4-rdmav2
libmlx4-fix_type_punning.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File libmlx4-fix_type_punning.patch of Package libmlx4-rdmav2
--- src/qp.c | 3 ++- src/verbs.c | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) Index: src/qp.c =================================================================== --- src/qp.c.orig 2016-02-10 10:57:47.000000000 +0100 +++ src/qp.c 2016-02-15 10:29:52.562442964 +0100 @@ -411,8 +411,9 @@ out: ctx = to_mctx(ibqp->context); if (nreq == 1 && inl && size > 1 && size <= ctx->bf_buf_size / 16) { + union{ uint8_t *ui8p; uint32_t *ui32p; }pun = { ctrl->reserved }; ctrl->owner_opcode |= htonl((qp->sq.head & 0xffff) << 8); - *(uint32_t *) ctrl->reserved |= qp->doorbell_qpn; + *pun.ui32p |= qp->doorbell_qpn; /* * Make sure that descriptor is written to memory * before writing to BlueFlame page. Index: src/verbs.c =================================================================== --- src/verbs.c.orig 2016-02-10 10:57:47.000000000 +0100 +++ src/verbs.c 2016-02-15 10:29:52.562442964 +0100 @@ -784,8 +784,10 @@ int mlx4_destroy_qp(struct ibv_qp *ibqp) static int link_local_gid(const union ibv_gid *gid) { - uint32_t hi = *(uint32_t *)(gid->raw); - uint32_t lo = *(uint32_t *)(gid->raw + 4); + uint32_t hi, lo; + memcpy(&hi, gid->raw, sizeof(uint32_t)); + memcpy(&lo, gid->raw + 4, sizeof(uint32_t)); + if (hi == htonl(0xfe800000) && lo == 0) return 1;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor