summaryrefslogtreecommitdiff
path: root/promisc.c
blob: 32184b12e13753e9ad31ffb95a4a9ae42cf234c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include <string.h>
#include <sys/socket.h>
#include <linux/if.h>

#include "promisc.h"
#include "dev.h"

short enter_promiscuous_mode(char *ifname)
{
	short ifflags;

	if (!strncmp("any", ifname, strlen("any")))
		return 0;

	ifflags = device_get_flags(ifname);
	device_set_flags(ifname, ifflags | IFF_PROMISC);

	return ifflags;
}

void leave_promiscuous_mode(char *ifname, short oldflags)
{
	if (!strncmp("any", ifname, strlen("any")))
		return;

	device_set_flags(ifname, oldflags);
}
16-09-06 14:17:55 +0530 committerMark Brown <broonie@kernel.org>2016-09-14 16:35:00 +0100 commitf11766143caa065b3aef4d794c104ea0f37ada76 (patch) tree42b4d991838a6709fe47171919d33f00c453b86a /sound/soc/sh parent29b4817d4018df78086157ea3a55c1d9424a7cfc (diff)
ASoC: dpcm: Don't apply symmetry for BE with hw param fixup
If be_hw_param_fixup is defined for BE then it will force the BE to a specific configuration supported by HW. In this case don't apply symmetry. Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sh')