1719f82d3SEliot Blennerhassett /****************************************************************************** 2719f82d3SEliot Blennerhassett 3719f82d3SEliot Blennerhassett AudioScience HPI driver 4719f82d3SEliot Blennerhassett Copyright (C) 1997-2010 AudioScience Inc. <support@audioscience.com> 5719f82d3SEliot Blennerhassett 6719f82d3SEliot Blennerhassett This program is free software; you can redistribute it and/or modify 7719f82d3SEliot Blennerhassett it under the terms of version 2 of the GNU General Public License as 8719f82d3SEliot Blennerhassett published by the Free Software Foundation; 9719f82d3SEliot Blennerhassett 10719f82d3SEliot Blennerhassett This program is distributed in the hope that it will be useful, 11719f82d3SEliot Blennerhassett but WITHOUT ANY WARRANTY; without even the implied warranty of 12719f82d3SEliot Blennerhassett MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13719f82d3SEliot Blennerhassett GNU General Public License for more details. 14719f82d3SEliot Blennerhassett 15719f82d3SEliot Blennerhassett You should have received a copy of the GNU General Public License 16719f82d3SEliot Blennerhassett along with this program; if not, write to the Free Software 17719f82d3SEliot Blennerhassett Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18719f82d3SEliot Blennerhassett 19719f82d3SEliot Blennerhassett Hardware Programming Interface (HPI) Utility functions 20719f82d3SEliot Blennerhassett 21719f82d3SEliot Blennerhassett (C) Copyright AudioScience Inc. 2007 22719f82d3SEliot Blennerhassett *******************************************************************************/ 23719f82d3SEliot Blennerhassett /* Initialise response headers, or msg/response pairs. 2414652e67SEliot Blennerhassett Note that it is valid to just init a response e.g. when a lower level is 2514652e67SEliot Blennerhassett preparing a response to a message. 2614652e67SEliot Blennerhassett However, when sending a message, a matching response buffer must always be 2714652e67SEliot Blennerhassett prepared. 28719f82d3SEliot Blennerhassett */ 29719f82d3SEliot Blennerhassett 3014652e67SEliot Blennerhassett #ifndef _HPIMSGINIT_H_ 3114652e67SEliot Blennerhassett #define _HPIMSGINIT_H_ 3214652e67SEliot Blennerhassett 33719f82d3SEliot Blennerhassett void hpi_init_response(struct hpi_response *phr, u16 object, u16 function, 34719f82d3SEliot Blennerhassett u16 error); 35719f82d3SEliot Blennerhassett 36719f82d3SEliot Blennerhassett void hpi_init_message_response(struct hpi_message *phm, 37719f82d3SEliot Blennerhassett struct hpi_response *phr, u16 object, u16 function); 38719f82d3SEliot Blennerhassett 39719f82d3SEliot Blennerhassett void hpi_init_responseV1(struct hpi_response_header *phr, u16 size, 40719f82d3SEliot Blennerhassett u16 object, u16 function); 41719f82d3SEliot Blennerhassett 42719f82d3SEliot Blennerhassett void hpi_init_message_responseV1(struct hpi_message_header *phm, u16 msg_size, 43719f82d3SEliot Blennerhassett struct hpi_response_header *phr, u16 res_size, u16 object, 44719f82d3SEliot Blennerhassett u16 function); 4514652e67SEliot Blennerhassett 4614652e67SEliot Blennerhassett #endif /* _HPIMSGINIT_H_ */ 47