m.BDEV_GRANT = grant_nr;
m.BDEV_FLAGS = BDEV_NOPAGE; /* the EEPROMs used for EDID are pageless */
m.BDEV_ID = 0;
- m.BDEV_POS_LO = 0;
- m.BDEV_POS_HI = 0;
+ m.BDEV_POS = 0;
r = ipc_sendrec(driver_endpt, &m);
cpf_revoke(grant_nr);
m.BDEV_GRANT = grant;
m.BDEV_FLAGS = flags;
m.BDEV_ID = 0;
- m.BDEV_POS_LO = ex64lo(position);
- m.BDEV_POS_HI = ex64hi(position);
+ m.BDEV_POS = position;
if ((r = ipc_sendrec(driver_endpt, &m)) != OK)
panic("ipc_sendrec to driver failed (%d)\n", r);
m.BDEV_GRANT = grant;
m.BDEV_FLAGS = flags;
m.BDEV_ID = 0;
- m.BDEV_POS_LO = ex64lo(position);
- m.BDEV_POS_HI = ex64hi(position);
+ m.BDEV_POS = position;
if ((r = ipc_sendrec(driver_endpt, &m)) != OK)
panic("ipc_sendrec to driver failed (%d)\n", r);
int r;
#if DEBUG2
- printf("paired_sendrec(%d) - <%d,%lx:%lx,%d> - %x,%x\n",
- both, m1->m_type, m1->BDEV_POS_HI, m1->BDEV_POS_LO,
+ printf("paired_sendrec(%d) - <%d,%llx,%d> - %x,%x\n",
+ both, m1->m_type, m1->BDEV_POS,
m1->BDEV_COUNT, m1->BDEV_GRANT, m2->BDEV_GRANT);
#endif
memset(&m1, 0, sizeof(m1));
m1.m_type = (request == FLT_WRITE) ? BDEV_SCATTER : BDEV_GATHER;
m1.BDEV_COUNT = count;
- m1.BDEV_POS_LO = ex64lo(pos);
- m1.BDEV_POS_HI = ex64hi(pos);
+ m1.BDEV_POS = pos;
m2 = m1;
#define BDEV_USER m10_i4 /* user endpoint requesting I/O control */
#define BDEV_ID m10_l1 /* opaque request ID */
#define BDEV_REQUEST m10_l2 /* I/O control request */
-#define BDEV_POS_LO m10_l2 /* transfer position (low bits) */
-#define BDEV_POS_HI m10_l3 /* transfer position (high bits) */
+#define BDEV_POS m10_ull1 /* transfer position */
/* Bits in 'BDEV_ACCESS' field of block device open requests. */
# define BDEV_R_BIT 0x01 /* open with read access */
_ASSERT_MSG_SIZE(mess_9);
typedef struct {
+ u64_t m10ull1;
int m10i1, m10i2, m10i3, m10i4;
long m10l1, m10l2, m10l3;
- uint8_t padding[28];
+ uint8_t padding[20];
} mess_10;
_ASSERT_MSG_SIZE(mess_10);
#define m10_l1 m_m10.m10l1
#define m10_l2 m_m10.m10l2
#define m10_l3 m_m10.m10l3
+#define m10_ull1 m_m10.m10ull1
#define m11_i1 m_m11.m11i1
#define m11_s1 m_m11.m11s1
memset(m, 0, sizeof(*m));
m->m_type = req;
m->BDEV_MINOR = minor(dev);
- m->BDEV_POS_LO = ex64lo(pos);
- m->BDEV_POS_HI = ex64hi(pos);
+ m->BDEV_POS = pos;
m->BDEV_COUNT = count;
m->BDEV_GRANT = grant;
m->BDEV_FLAGS = flags;
memset(m, 0, sizeof(*m));
m->m_type = req;
m->BDEV_MINOR = minor(dev);
- m->BDEV_POS_LO = ex64lo(pos);
- m->BDEV_POS_HI = ex64hi(pos);
+ m->BDEV_POS = pos;
m->BDEV_COUNT = count;
m->BDEV_GRANT = grant;
m->BDEV_FLAGS = flags;
bdev_rdwt_cleanup(&call->msg);
r = bdev_rdwt_setup(type, call->dev,
- make64(call->msg.BDEV_POS_LO, call->msg.BDEV_POS_HI),
+ call->msg.BDEV_POS,
(char *) call->vec[0].iov_addr, call->msg.BDEV_COUNT,
call->msg.BDEV_FLAGS, &call->msg);
bdev_vrdwt_cleanup(&call->msg, call->gvec);
r = bdev_vrdwt_setup(type, call->dev,
- make64(call->msg.BDEV_POS_LO, call->msg.BDEV_POS_HI),
+ call->msg.BDEV_POS,
call->vec, call->msg.BDEV_COUNT, call->msg.BDEV_FLAGS,
&call->msg, call->gvec);
* Field names are prefixed with BDEV_. Separate field names are used for the
* "access", "request", and "user" fields.
*
- * m_type MINOR COUNT GRANT FLAGS ID POS_LO POS_HI
+ * m_type MINOR COUNT GRANT FLAGS ID REQUEST POS
* +--------------+--------+----------+-------+-------+------+---------+------+
* | BDEV_OPEN | minor | access | | | id | | |
* |--------------+--------+----------+-------+-------+------+---------+------|
* | BDEV_CLOSE | minor | | | | id | | |
* |--------------+--------+----------+-------+-------+------+---------+------|
- * | BDEV_READ | minor | bytes | grant | flags | id | position |
+ * | BDEV_READ | minor | bytes | grant | flags | id | | pos. |
* |--------------+--------+----------+-------+-------+------+---------+------|
- * | BDEV_WRITE | minor | bytes | grant | flags | id | position |
+ * | BDEV_WRITE | minor | bytes | grant | flags | id | | pos. |
* |--------------+--------+----------+-------+-------+------+---------+------|
- * | BDEV_GATHER | minor | elements | grant | flags | id | position |
+ * | BDEV_GATHER | minor | elements | grant | flags | id | | pos. |
* |--------------+--------+----------+-------+-------+------+---------+------|
- * | BDEV_SCATTER | minor | elements | grant | flags | id | position |
+ * | BDEV_SCATTER | minor | elements | grant | flags | id | | pos. |
* |--------------+--------+----------+-------+-------+------+---------+------|
* | BDEV_IOCTL | minor | | grant | user | id | request | |
* ----------------------------------------------------------------------------
/* Transfer bytes from/to the device. */
do_write = (mp->m_type == BDEV_WRITE);
- position = make64(mp->BDEV_POS_LO, mp->BDEV_POS_HI);
+ position = mp->BDEV_POS;
r = (*bdp->bdr_transfer)(mp->BDEV_MINOR, do_write, position, mp->m_source,
&iovec1, 1, mp->BDEV_FLAGS);
/* Transfer bytes from/to the device. */
do_write = (mp->m_type == BDEV_SCATTER);
- position = make64(mp->BDEV_POS_LO, mp->BDEV_POS_HI);
+ position = mp->BDEV_POS;
r = (*bdp->bdr_transfer)(mp->BDEV_MINOR, do_write, position, mp->m_source,
iovec, nr_req, mp->BDEV_FLAGS);
case BDEV_WRITE:
case BDEV_GATHER:
case BDEV_SCATTER:
- pos = make64(m_ptr->BDEV_POS_LO, m_ptr->BDEV_POS_HI);
+ pos = m_ptr->BDEV_POS;
size = m_ptr->BDEV_COUNT;
flags = m_ptr->BDEV_FLAGS;
memset(&m, 0, sizeof(m));
m.m_type = write ? BDEV_SCATTER : BDEV_GATHER;
m.BDEV_MINOR = minor;
- m.BDEV_POS_LO = ex64lo(pos);
- m.BDEV_POS_HI = ex64hi(pos);
+ m.BDEV_POS = pos;
m.BDEV_COUNT = nr_req;
m.BDEV_GRANT = grant;
m.BDEV_ID = lrand48();
memset(&mt, 0, sizeof(mt));
mt.m_type = BDEV_GATHER;
mt.BDEV_MINOR = driver_minor;
- mt.BDEV_POS_LO = 0L;
- mt.BDEV_POS_HI = 0L;
+ mt.BDEV_POS = 0LL;
mt.BDEV_COUNT = 1;
mt.BDEV_GRANT = grant;
mt.BDEV_ID = lrand48();