DMUB_RB_CMD_SIZE
#define DMUB_RB_SIZE (DMUB_RB_CMD_SIZE * DMUB_RB_MAX_ENTRY)
#define DMUB_REG_INBOX0_RB_SIZE (DMUB_RB_CMD_SIZE * DMUB_REG_INBOX0_RB_MAX_ENTRY)
uint8_t cmd_buffer[DMUB_RB_CMD_SIZE - sizeof(struct dmub_cmd_header)];
uint8_t cmd_buffer[DMUB_RB_CMD_SIZE - sizeof(struct dmub_cmd_header)
return data_count / DMUB_RB_CMD_SIZE;
data_count += DMUB_RB_CMD_SIZE;
return (rb->capacity - data_count) / DMUB_RB_CMD_SIZE;
return (data_count == (rb->capacity - DMUB_RB_CMD_SIZE));
for (i = 0; i < DMUB_RB_CMD_SIZE; i++)
rb->wrpt += DMUB_RB_CMD_SIZE;
dmub_memcpy(dst, src, DMUB_RB_CMD_SIZE);
rb->wrpt += DMUB_RB_CMD_SIZE;
*next_rptr = rb->rptr + DMUB_RB_CMD_SIZE * num_cmds;
for (i = 0; i < DMUB_RB_CMD_SIZE / sizeof(uint64_t); i++)
rb->rptr += DMUB_RB_CMD_SIZE;
for (i = 0; i < DMUB_RB_CMD_SIZE / sizeof(uint64_t); i++)
rptr += DMUB_RB_CMD_SIZE;
(uint8_t *)rb->base_address + rb->capacity - DMUB_RB_CMD_SIZE :
(uint8_t *)rb->base_address + rb->rptr - DMUB_RB_CMD_SIZE;
dmub_memcpy(cmd, rd_ptr, DMUB_RB_CMD_SIZE);
dmub->inbox1.num_reported += (rptr + dmub->inbox1.rb.capacity - dmub->inbox1.rb.rptr) / DMUB_RB_CMD_SIZE;
dmub->inbox1.num_reported += (rptr - dmub->inbox1.rb.rptr) / DMUB_RB_CMD_SIZE;