/* Read data from the specified page in AT24MACXX.  */
uint32_t at24macxx_read_page(uint32_t u32_page_address, uint32_t u32_page_size, uint8_t *p_rd_buffer)
/* Read data from the specified page in AT24MACXX.  */
uint32_t at24macxx_read_page(uint32_t u32_page_address, uint32_t u32_page_size, uint8_t *p_rd_buffer)
{
	twihs_package_t twihs_package;
	uint32_t start_address = (u32_page_address * u32_page_size) & 0xFFFF;
	twihs_package.chip = BOARD_AT24MAC_ADDRESS;
	at24mac_build_word_address(twihs_package.addr, start_address);
	twihs_package.addr_length = AT24MAC_MEM_ADDR_LEN;
	twihs_package.buffer = p_rd_buffer;
	twihs_package.length = u32_page_size;
	if (twihs_master_read(BOARD_AT24MAC_TWIHS_INSTANCE, &twihs_package) !=
			TWIHS_SUCCESS) {
		return AT24MAC_READ_FAIL;
	}
	return AT24MAC_READ_SUCCESS;
}