/*
   Copyright (c) 2011,2012 Intel Corp.

   This program is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License version 2 and
   only version 2 as published by the Free Software Foundation.

   This program is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   GNU General Public License for more details.
*/

#ifndef __AMP_H
#define __AMP_H

struct amp_ctrl {
	struct list_head	list;
	struct kref		kref;
	__u8			id;
	__u16			assoc_len_so_far;
	__u16			assoc_rem_len;
	__u16			assoc_len;
	__u8			*assoc;
};

int amp_ctrl_put(struct amp_ctrl *ctrl);
void amp_ctrl_get(struct amp_ctrl *ctrl);
struct amp_ctrl *amp_ctrl_add(struct amp_mgr *mgr, u8 id);
struct amp_ctrl *amp_ctrl_lookup(struct amp_mgr *mgr, u8 id);
void amp_ctrl_list_flush(struct amp_mgr *mgr);

struct hci_conn *phylink_add(struct hci_dev *hdev, struct amp_mgr *mgr,
			     u8 remote_id, bool out);

int phylink_gen_key(struct hci_conn *hcon, u8 *data, u8 *len, u8 *type);

void amp_read_loc_info(struct hci_dev *hdev, struct amp_mgr *mgr);
void amp_read_loc_assoc_frag(struct hci_dev *hdev, u8 phy_handle);
void amp_read_loc_assoc(struct hci_dev *hdev, struct amp_mgr *mgr);
void amp_read_loc_assoc_final_data(struct hci_dev *hdev,
				   struct hci_conn *hcon);
void amp_create_phylink(struct hci_dev *hdev, struct amp_mgr *mgr,
			struct hci_conn *hcon);
void amp_accept_phylink(struct hci_dev *hdev, struct amp_mgr *mgr,
			struct hci_conn *hcon);

#if IS_ENABLED(CONFIG_BT_HS)
void amp_create_logical_link(struct l2cap_chan *chan);
void amp_disconnect_logical_link(struct hci_chan *hchan);
#else
static inline void amp_create_logical_link(struct l2cap_chan *chan)
{
}

static inline void amp_disconnect_logical_link(struct hci_chan *hchan)
{
}
#endif

void amp_write_remote_assoc(struct hci_dev *hdev, u8 handle);
void amp_write_rem_assoc_continue(struct hci_dev *hdev, u8 handle);
void amp_physical_cfm(struct hci_conn *bredr_hcon, struct hci_conn *hs_hcon);
void amp_create_logical_link(struct l2cap_chan *chan);
void amp_disconnect_logical_link(struct hci_chan *hchan);
void amp_destroy_logical_link(struct hci_chan *hchan, u8 reason);

#endif /* __AMP_H */
ion='/cgit.cgi/linux/net-next.git/log/sound/soc/sh'>
<input type='hidden' name='h' value='nds-private-remove'/><input type='hidden' name='id' value='04d8a0a5f3b6887543850d991a5e37c4ec90e250'/><select name='qt'>
<option value='grep'>log msg</option>
<option value='author'>author</option>
<option value='committer'>committer</option>
<option value='range'>range</option>
</select>
<input class='txt' type='search' size='10' name='q' value=''/>
<input type='submit' value='search'/>
</form>
</td></tr></table>
<div class='path'>path: <a href='/cgit.cgi/linux/net-next.git/commit/?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>root</a>/<a href='/cgit.cgi/linux/net-next.git/commit/sound?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>sound</a>/<a href='/cgit.cgi/linux/net-next.git/commit/sound/soc?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>soc</a>/<a href='/cgit.cgi/linux/net-next.git/commit/sound/soc/sh?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>sh</a></div><div class='content'><div class='cgit-panel'><b>diff options</b><form method='get'><input type='hidden' name='h' value='nds-private-remove'/><input type='hidden' name='id' value='04d8a0a5f3b6887543850d991a5e37c4ec90e250'/><table><tr><td colspan='2'/></tr><tr><td class='label'>context:</td><td class='ctrl'><select name='context' onchange='this.form.submit();'><option value='1'>1</option><option value='2'>2</option><option value='3' selected='selected'>3</option><option value='4'>4</option><option value='5'>5</option><option value='6'>6</option><option value='7'>7</option><option value='8'>8</option><option value='9'>9</option><option value='10'>10</option><option value='15'>15</option><option value='20'>20</option><option value='25'>25</option><option value='30'>30</option><option value='35'>35</option><option value='40'>40</option></select></td></tr><tr><td class='label'>space:</td><td class='ctrl'><select name='ignorews' onchange='this.form.submit();'><option value='0' selected='selected'>include</option><option value='1'>ignore</option></select></td></tr><tr><td class='label'>mode:</td><td class='ctrl'><select name='dt' onchange='this.form.submit();'><option value='0' selected='selected'>unified</option><option value='1'>ssdiff</option><option value='2'>stat only</option></select></td></tr><tr><td/><td class='ctrl'><noscript><input type='submit' value='reload'/></noscript></td></tr></table></form></div><table summary='commit info' class='commit-info'>
<tr><th>author</th><td>Raju Lakkaraju &lt;Raju.Lakkaraju@microsemi.com&gt;</td><td class='right'>2017-02-07 19:10:26 +0530</td></tr>
<tr><th>committer</th><td>David S. Miller &lt;davem@davemloft.net&gt;</td><td class='right'>2017-02-08 13:29:04 -0500</td></tr>
<tr><th>commit</th><td colspan='2' class='oid'><a href='/cgit.cgi/linux/net-next.git/commit/sound/soc/sh?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>04d8a0a5f3b6887543850d991a5e37c4ec90e250</a> (<a href='/cgit.cgi/linux/net-next.git/patch/sound/soc/sh?id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>patch</a>)</td></tr>
<tr><th>tree</th><td colspan='2' class='oid'><a href='/cgit.cgi/linux/net-next.git/tree/?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>ee1fafb2122c2b29c7cb19e571bd7229afdbf847</a> /<a href='/cgit.cgi/linux/net-next.git/tree/sound/soc/sh?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>sound/soc/sh</a></td></tr>
<tr><th>parent</th><td colspan='2' class='oid'><a href='/cgit.cgi/linux/net-next.git/commit/sound/soc/sh?h=nds-private-remove&amp;id=ff4cf0e5ce952488074aa7f47734af1794f55fbc'>ff4cf0e5ce952488074aa7f47734af1794f55fbc</a> (<a href='/cgit.cgi/linux/net-next.git/diff/sound/soc/sh?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250&amp;id2=ff4cf0e5ce952488074aa7f47734af1794f55fbc'>diff</a>)</td></tr></table>
<div class='commit-subject'>net: phy: Add LED mode driver for Microsemi PHYs.</div><div class='commit-msg'>LED Mode:
Microsemi PHY support 2 LEDs (LED[0] and LED[1]) to display different
status information that can be selected by setting LED mode.

LED Mode parameter (vsc8531, led-0-mode) and (vsc8531, led-1-mode) get
from Device Tree.

Signed-off-by: Raju Lakkaraju &lt;Raju.Lakkaraju@microsemi.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</div><div class='diffstat-header'><a href='/cgit.cgi/linux/net-next.git/diff/?h=nds-private-remove&amp;id=04d8a0a5f3b6887543850d991a5e37c4ec90e250'>Diffstat</a> (limited to 'sound/soc/sh')</div><table summary='diffstat' class='diffstat'>