summaryrefslogtreecommitdiffstats
path: root/drivers/staging/most/mostcore/mostcore.h
diff options
context:
space:
mode:
authorChristian Gromm2015-09-28 17:18:45 +0200
committerGreg Kroah-Hartman2015-09-29 03:18:51 +0200
commit71457d482751a38e78da32fde80e87b6f670c389 (patch)
tree5a5c845fb2a78d9c33ee48b1448473316af73cfa /drivers/staging/most/mostcore/mostcore.h
parentstaging: most: consolidate code (diff)
downloadkernel-qcow2-linux-71457d482751a38e78da32fde80e87b6f670c389.tar.gz
kernel-qcow2-linux-71457d482751a38e78da32fde80e87b6f670c389.tar.xz
kernel-qcow2-linux-71457d482751a38e78da32fde80e87b6f670c389.zip
staging: most: add fair buffer distribution
This patch ensures a fair distribution of buffers, when two AIMs share a single channel. The AIMs then won't be able to use more than half of all pre-allocated buffers of the linked channel. However, in case the channel is not shared, the AIM can exclusively use all available buffers. Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de> Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/most/mostcore/mostcore.h')
-rw-r--r--drivers/staging/most/mostcore/mostcore.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/staging/most/mostcore/mostcore.h b/drivers/staging/most/mostcore/mostcore.h
index e23ad7c33249..3c6fb19aaa3b 100644
--- a/drivers/staging/most/mostcore/mostcore.h
+++ b/drivers/staging/most/mostcore/mostcore.h
@@ -190,6 +190,7 @@ struct mbo {
void *priv;
struct list_head list;
struct most_interface *ifp;
+ int *num_buffers_ptr;
u16 hdm_channel_id;
void *virt_address;
dma_addr_t bus_address;
@@ -307,7 +308,8 @@ void most_stop_enqueue(struct most_interface *iface, int channel_idx);
void most_resume_enqueue(struct most_interface *iface, int channel_idx);
int most_register_aim(struct most_aim *aim);
int most_deregister_aim(struct most_aim *aim);
-struct mbo *most_get_mbo(struct most_interface *iface, int channel_idx);
+struct mbo *most_get_mbo(struct most_interface *iface, int channel_idx,
+ struct most_aim *);
void most_put_mbo(struct mbo *mbo);
int most_start_channel(struct most_interface *iface, int channel_idx,
struct most_aim *);