type
stringclasses
5 values
content
stringlengths
9
163k
functions
int inet6_dump_ifmcaddr(struct sk_buff *skb, struct netlink_callback *cb) { enum addr_type_t type = MULTICAST_ADDR; return inet6_dump_addr(skb, cb, type); }
functions
int inet6_dump_ifacaddr(struct sk_buff *skb, struct netlink_callback *cb) { enum addr_type_t type = ANYCAST_ADDR; return inet6_dump_addr(skb, cb, type); }
functions
int inet6_rtm_getaddr(struct sk_buff *in_skb, struct nlmsghdr* nlh, void *arg) { struct net *net = sock_net(in_skb->sk); struct ifaddrmsg *ifm; struct nlattr *tb[IFA_MAX+1]; struct in6_addr *addr = NULL; struct net_device *dev = NULL; struct inet6_ifaddr *ifa; struct sk_buff *skb; int err; err = nlmsg...
functions
void inet6_ifa_notify(int event, struct inet6_ifaddr *ifa) { struct sk_buff *skb; struct net *net = dev_net(ifa->idev->dev); int err = -ENOBUFS; skb = nlmsg_new(inet6_ifaddr_msgsize(), GFP_ATOMIC); if (skb == NULL) goto errout; err = inet6_fill_ifaddr(skb, ifa, 0, 0, event, 0); if (err < 0) { /* -EMSGSIZE ...
functions
void ipv6_store_devconf(struct ipv6_devconf *cnf, __s32 *array, int bytes) { BUG_ON(bytes < (DEVCONF_MAX * 4)); memset(array, 0, bytes); array[DEVCONF_FORWARDING] = cnf->forwarding; array[DEVCONF_HOPLIMIT] = cnf->hop_limit; array[DEVCONF_MTU6] = cnf->mtu6; array[DEVCONF_ACCEPT_RA] = cnf->accept_ra; array[DE...
functions
size_t inet6_ifla6_size(void) { return nla_total_size(4) /* IFLA_INET6_FLAGS */ + nla_total_size(sizeof(struct ifla_cacheinfo)) + nla_total_size(DEVCONF_MAX * 4) /* IFLA_INET6_CONF */ + nla_total_size(IPSTATS_MIB_MAX * 8) /* IFLA_INET6_STATS */ + nla_total_size(ICMP6_MIB_MAX * 8); /* IFLA_INET6...
functions
size_t inet6_if_nlmsg_size(void) { return NLMSG_ALIGN(sizeof(struct ifinfomsg)) + nla_total_size(IFNAMSIZ) /* IFLA_IFNAME */ + nla_total_size(MAX_ADDR_LEN) /* IFLA_ADDRESS */ + nla_total_size(4) /* IFLA_MTU */ + nla_total_size(4) /* IFLA_LINK */ + nla_total_size(inet6_ifla6_size...
functions
void __snmp6_fill_statsdev(u64 *stats, atomic_long_t *mib, int items, int bytes) { int i; int pad = bytes - sizeof(u64) * items; BUG_ON(pad < 0); /* Use put_unaligned() because stats may not be aligned for u64. */ put_unaligned(items, &stats[0]); for (i = 1; i < items; i++) put_unaligned(atomic_long_...
functions
void __snmp6_fill_stats64(u64 *stats, void __percpu **mib, int items, int bytes, size_t syncpoff) { int i; int pad = bytes - sizeof(u64) * items; BUG_ON(pad < 0); /* Use put_unaligned() because stats may not be aligned for u64. */ put_unaligned(items, &stats[0]); for (i = 1; i < items; i++) put_unali...
functions
void snmp6_fill_stats(u64 *stats, struct inet6_dev *idev, int attrtype, int bytes) { switch (attrtype) { case IFLA_INET6_STATS: __snmp6_fill_stats64(stats, (void __percpu **)idev->stats.ipv6, IPSTATS_MIB_MAX, bytes, offsetof(struct ipstats_mib, syncp)); break; case IFLA_INET6_ICMP6STATS: __snm...
functions
int inet6_fill_ifla6_attrs(struct sk_buff *skb, struct inet6_dev *idev) { struct nlattr *nla; struct ifla_cacheinfo ci; NLA_PUT_U32(skb, IFLA_INET6_FLAGS, idev->if_flags); ci.max_reasm_len = IPV6_MAXPLEN; ci.tstamp = cstamp_delta(idev->tstamp); ci.reachable_time = jiffies_to_msecs(idev->nd_parms->reachable_time...
functions
size_t inet6_get_link_af_size(const struct net_device *dev) { if (!__in6_dev_get(dev)) return 0; return inet6_ifla6_size(); }
functions
int inet6_fill_link_af(struct sk_buff *skb, const struct net_device *dev) { struct inet6_dev *idev = __in6_dev_get(dev); if (!idev) return -ENODATA; if (inet6_fill_ifla6_attrs(skb, idev) < 0) return -EMSGSIZE; return 0; }
functions
int inet6_fill_ifinfo(struct sk_buff *skb, struct inet6_dev *idev, u32 pid, u32 seq, int event, unsigned int flags) { struct net_device *dev = idev->dev; struct ifinfomsg *hdr; struct nlmsghdr *nlh; void *protoinfo; nlh = nlmsg_put(skb, pid, seq, event, sizeof(*hdr), flags); if (nlh == NULL) return -EM...
functions
int inet6_dump_ifinfo(struct sk_buff *skb, struct netlink_callback *cb) { struct net *net = sock_net(skb->sk); int h, s_h; int idx = 0, s_idx; struct net_device *dev; struct inet6_dev *idev; struct hlist_head *head; struct hlist_node *node; s_h = cb->args[0]; s_idx = cb->args[1]; rcu_read_lock(); for (h = ...
functions
void inet6_ifinfo_notify(int event, struct inet6_dev *idev) { struct sk_buff *skb; struct net *net = dev_net(idev->dev); int err = -ENOBUFS; skb = nlmsg_new(inet6_if_nlmsg_size(), GFP_ATOMIC); if (skb == NULL) goto errout; err = inet6_fill_ifinfo(skb, idev, 0, 0, event, 0); if (err < 0) { /* -EMSGSIZE impl...
functions
size_t inet6_prefix_nlmsg_size(void) { return NLMSG_ALIGN(sizeof(struct prefixmsg)) + nla_total_size(sizeof(struct in6_addr)) + nla_total_size(sizeof(struct prefix_cacheinfo)); }
functions
int inet6_fill_prefix(struct sk_buff *skb, struct inet6_dev *idev, struct prefix_info *pinfo, u32 pid, u32 seq, int event, unsigned int flags) { struct prefixmsg *pmsg; struct nlmsghdr *nlh; struct prefix_cacheinfo ci; nlh = nlmsg_put(skb, pid, seq, event, sizeof(*pmsg), flags); if (nlh == NULL) ...
functions
void inet6_prefix_notify(int event, struct inet6_dev *idev, struct prefix_info *pinfo) { struct sk_buff *skb; struct net *net = dev_net(idev->dev); int err = -ENOBUFS; skb = nlmsg_new(inet6_prefix_nlmsg_size(), GFP_ATOMIC); if (skb == NULL) goto errout; err = inet6_fill_prefix(skb, idev, pinfo, 0, 0, even...
functions
void __ipv6_ifa_notify(int event, struct inet6_ifaddr *ifp) { inet6_ifa_notify(event ? : RTM_NEWADDR, ifp); switch (event) { case RTM_NEWADDR: /* * If the address was optimistic * we inserted the route at the start of * our DAD process, so we don't need * to do it again */ if (!(ifp->rt->rt6i_nod...
functions
void ipv6_ifa_notify(int event, struct inet6_ifaddr *ifp) { rcu_read_lock_bh(); if (likely(ifp->idev->dead == 0)) __ipv6_ifa_notify(event, ifp); rcu_read_unlock_bh(); }
functions
int addrconf_sysctl_forward(ctl_table *ctl, int write, void __user *buffer, size_t *lenp, loff_t *ppos) { int *valp = ctl->data; int val = *valp; loff_t pos = *ppos; ctl_table lctl; int ret; /* * ctl->data points to idev->cnf.forwarding, we should * not modify it until we get the rtnl lock. */ lctl ...
functions
void dev_disable_change(struct inet6_dev *idev) { if (!idev || !idev->dev) return; if (idev->cnf.disable_ipv6) addrconf_notify(NULL, NETDEV_DOWN, idev->dev); else addrconf_notify(NULL, NETDEV_UP, idev->dev); }
functions
void addrconf_disable_change(struct net *net, __s32 newf) { struct net_device *dev; struct inet6_dev *idev; rcu_read_lock(); for_each_netdev_rcu(net, dev) { idev = __in6_dev_get(dev); if (idev) { int changed = (!idev->cnf.disable_ipv6) ^ (!newf); idev->cnf.disable_ipv6 = newf; if (changed) dev_dis...
functions
int addrconf_disable_ipv6(struct ctl_table *table, int *p, int newf) { struct net *net; int old; if (!rtnl_trylock()) return restart_syscall(); net = (struct net *)table->extra2; old = *p; *p = newf; if (p == &net->ipv6.devconf_dflt->disable_ipv6) { rtnl_unlock(); return 0; }
functions
int addrconf_sysctl_disable(ctl_table *ctl, int write, void __user *buffer, size_t *lenp, loff_t *ppos) { int *valp = ctl->data; int val = *valp; loff_t pos = *ppos; ctl_table lctl; int ret; /* * ctl->data points to idev->cnf.disable_ipv6, we should * not modify it until we get the rtnl lock. */ lc...
functions
int __addrconf_sysctl_register(struct net *net, char *dev_name, struct inet6_dev *idev, struct ipv6_devconf *p) { int i; struct addrconf_sysctl_table *t; struct ctl_path addrconf_ctl_path[] = { { .procname = "net", }
functions
void __addrconf_sysctl_unregister(struct ipv6_devconf *p) { struct addrconf_sysctl_table *t; if (p->sysctl == NULL) return; t = p->sysctl; p->sysctl = NULL; unregister_net_sysctl_table(t->sysctl_header); kfree(t->dev_name); kfree(t); }
functions
void addrconf_sysctl_register(struct inet6_dev *idev) { neigh_sysctl_register(idev->dev, idev->nd_parms, "ipv6", &ndisc_ifinfo_sysctl_change); __addrconf_sysctl_register(dev_net(idev->dev), idev->dev->name, idev, &idev->cnf); }
functions
void addrconf_sysctl_unregister(struct inet6_dev *idev) { __addrconf_sysctl_unregister(&idev->cnf); neigh_sysctl_unregister(idev->nd_parms); }
functions
__net_init addrconf_init_net(struct net *net) { int err = -ENOMEM; struct ipv6_devconf *all, *dflt; all = kmemdup(&ipv6_devconf, sizeof(ipv6_devconf), GFP_KERNEL); if (all == NULL) goto err_alloc_all; dflt = kmemdup(&ipv6_devconf_dflt, sizeof(ipv6_devconf_dflt), GFP_KERNEL); if (dflt == NULL) goto err_alloc...
functions
__net_exit addrconf_exit_net(struct net *net) { #ifdef CONFIG_SYSCTL __addrconf_sysctl_unregister(net->ipv6.devconf_dflt); __addrconf_sysctl_unregister(net->ipv6.devconf_all); #endif if (!net_eq(net, &init_net)) { kfree(net->ipv6.devconf_dflt); kfree(net->ipv6.devconf_all); }
functions
int register_inet6addr_notifier(struct notifier_block *nb) { return atomic_notifier_chain_register(&inet6addr_chain, nb); }
functions
int unregister_inet6addr_notifier(struct notifier_block *nb) { return atomic_notifier_chain_unregister(&inet6addr_chain, nb); }
functions
__init addrconf_init(void) { int i, err; err = ipv6_addr_label_init(); if (err < 0) { printk(KERN_CRIT "IPv6 Addrconf:" " cannot initialize default policy table: %d.\n", err); goto out; }
functions
void addrconf_cleanup(void) { struct net_device *dev; int i; unregister_netdevice_notifier(&ipv6_dev_notf); unregister_pernet_subsys(&addrconf_ops); ipv6_addr_label_cleanup(); rtnl_lock(); __rtnl_af_unregister(&inet6_ops); /* clean dev list */ for_each_netdev(&init_net, dev) { if (__in6_dev_get(dev) == N...
includes
#include <linux/types.h>
includes
#include <linux/bitops.h>
includes
#include <linux/clk.h>
includes
#include <linux/mutex.h>
includes
#include <mach/msm_hdmi_audio.h>
includes
#include <mach/clk.h>
includes
#include <mach/msm_iomap.h>
includes
#include <mach/socinfo.h>
defines
#define DEV_DBG_PREFIX "HDMI: "
defines
#define CEC_MSG_PRINT
defines
#define TOGGLE_CEC_HARDWARE_FSM
defines
#define MSM_HDMI_AUDIO_CHANNEL_2 0
defines
#define MSM_HDMI_AUDIO_CHANNEL_4 1
defines
#define MSM_HDMI_AUDIO_CHANNEL_6 2
defines
#define MSM_HDMI_AUDIO_CHANNEL_8 3
defines
#define MSM_HDMI_AUDIO_CHANNEL_MAX 4
defines
#define MSM_HDMI_AUDIO_CHANNEL_FORCE_32BIT 0x7FFFFFFF
defines
#define MSM_HDMI_SAMPLE_RATE_32KHZ 0
defines
#define MSM_HDMI_SAMPLE_RATE_44_1KHZ 1
defines
#define MSM_HDMI_SAMPLE_RATE_48KHZ 2
defines
#define MSM_HDMI_SAMPLE_RATE_88_2KHZ 3
defines
#define MSM_HDMI_SAMPLE_RATE_96KHZ 4
defines
#define MSM_HDMI_SAMPLE_RATE_176_4KHZ 5
defines
#define MSM_HDMI_SAMPLE_RATE_192KHZ 6
defines
#define MSM_HDMI_SAMPLE_RATE_MAX 7
defines
#define MSM_HDMI_SAMPLE_RATE_FORCE_32BIT 0x7FFFFFFF
defines
#define HDCP_DDC_STATUS 0x0128
defines
#define HDCP_DDC_CTRL_0 0x0120
defines
#define HDCP_DDC_CTRL_1 0x0124
defines
#define HDMI_DDC_CTRL 0x020C
defines
#define HPD_EVENT_OFFLINE 0
defines
#define HPD_EVENT_ONLINE 1
defines
#define SWITCH_SET_HDMI_AUDIO(d, force) \
defines
#define HDMI_MSM_CEC_REFTIMER_REFTIMER_ENABLE BIT(16)
defines
#define HDMI_MSM_CEC_REFTIMER_REFTIMER(___t) (((___t)&0xFFFF) << 0)
defines
#define HDMI_MSM_CEC_TIME_SIGNAL_FREE_TIME(___t) (((___t)&0x1FF) << 7)
defines
#define HDMI_MSM_CEC_TIME_ENABLE BIT(0)
defines
#define HDMI_MSM_CEC_ADDR_LOGICAL_ADDR(___la) (((___la)&0xFF) << 0)
defines
#define HDMI_MSM_CEC_CTRL_LINE_OE BIT(9)
defines
#define HDMI_MSM_CEC_CTRL_FRAME_SIZE(___sz) (((___sz)&0x1F) << 4)
defines
#define HDMI_MSM_CEC_CTRL_SOFT_RESET BIT(2)
defines
#define HDMI_MSM_CEC_CTRL_SEND_TRIG BIT(1)
defines
#define HDMI_MSM_CEC_CTRL_ENABLE BIT(0)
defines
#define HDMI_MSM_CEC_INT_FRAME_RD_DONE_MASK BIT(7)
defines
#define HDMI_MSM_CEC_INT_FRAME_RD_DONE_ACK BIT(6)
defines
#define HDMI_MSM_CEC_INT_FRAME_RD_DONE_INT BIT(6)
defines
#define HDMI_MSM_CEC_INT_MONITOR_MASK BIT(5)
defines
#define HDMI_MSM_CEC_INT_MONITOR_ACK BIT(4)
defines
#define HDMI_MSM_CEC_INT_MONITOR_INT BIT(4)
defines
#define HDMI_MSM_CEC_INT_FRAME_ERROR_MASK BIT(3)
defines
#define HDMI_MSM_CEC_INT_FRAME_ERROR_ACK BIT(2)
defines
#define HDMI_MSM_CEC_INT_FRAME_ERROR_INT BIT(2)
defines
#define HDMI_MSM_CEC_INT_FRAME_WR_DONE_MASK BIT(1)
defines
#define HDMI_MSM_CEC_INT_FRAME_WR_DONE_ACK BIT(0)
defines
#define HDMI_MSM_CEC_INT_FRAME_WR_DONE_INT BIT(0)
defines
#define HDMI_MSM_CEC_FRAME_WR_SUCCESS(___st) (((___st)&0xB) ==\
defines
#define HDMI_MSM_CEC_RETRANSMIT_NUM(___num) (((___num)&0xF) << 4)
defines
#define HDMI_MSM_CEC_RETRANSMIT_ENABLE BIT(0)
defines
#define HDMI_MSM_CEC_WR_DATA_DATA(___d) (((___d)&0xFF) << 8)
defines
#define HDMI_MSM_AUDIO_ARCS(pclk, ...) { pclk, __VA_ARGS__ }
defines
#define HDMI_AUDIO_CFG 0x01D0
defines
#define HDMI_AUDIO_ENGINE_ENABLE 1
defines
#define HDMI_AUDIO_FIFO_MASK 0x000000F0
defines
#define HDMI_AUDIO_FIFO_WATERMARK_SHIFT 4