#include #include #include #include #include #include "xenfs.h" #include "../xenbus/xenbus_comms.h" static ssize_t xsd_read(struct file *file, char __user *buf, size_t size, loff_t *off) { const char *str = (const char *)file->private_data; return simple_read_from_buffer(buf, size, off, str, strlen(str)); } static int xsd_release(struct inode *inode, struct file *file) { kfree(file->private_data); return 0; } static int xsd_kva_open(struct inode *inode, struct file *file) { file->private_data = (void *)kasprintf(GFP_KERNEL, "0x%p", xen_store_interface); if (!file->private_data) return -ENOMEM; return 0; } static int xsd_kva_mmap(struct file *file, struct vm_area_struct *vma) { size_t size = vma->vm_end - vma->vm_start; if ((size > PAGE_SIZE) || (vma->vm_pgoff != 0)) return -EINVAL; if (remap_pfn_range(vma, vma->vm_start, virt_to_pfn(xen_store_interface), size, vma->vm_page_prot)) return -EAGAIN; return 0; } const struct file_operations xsd_kva_file_ops = { .open = xsd_kva_open, .mmap = xsd_kva_mmap, .read = xsd_read, .release = xsd_release, }; static int xsd_port_open(struct inode *inode, struct file *file) { file->private_data = (void *)kasprintf(GFP_KERNEL, "%d", xen_store_evtchn); if (!file->private_data) return -ENOMEM; return 0; } const struct file_operations xsd_port_file_ops = { .open = xsd_port_open, .read = xsd_read, .release = xsd_release, }; ='/cgit.cgi/linux/net-next.git/?h=nds-private-remove'>summaryrefslogtreecommitdiff
ge='this.form.submit();'>
AgeCommit message (Expand)AuthorFilesLines
space:
mode:
authorRaju Lakkaraju <Raju.Lakkaraju@microsemi.com>2017-02-07 19:10:26 +0530
committerDavid S. Miller <davem@davemloft.net>2017-02-08 13:29:04 -0500
commit04d8a0a5f3b6887543850d991a5e37c4ec90e250 (patch)
treeee1fafb2122c2b29c7cb19e571bd7229afdbf847 /sound/soc/codecs/wm8510.h
parentff4cf0e5ce952488074aa7f47734af1794f55fbc (diff)
net: phy: Add LED mode driver for Microsemi PHYs.
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 <Raju.Lakkaraju@microsemi.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'sound/soc/codecs/wm8510.h')