Home
last modified time | relevance | path

Searched full:nvram (Results 1 – 25 of 1170) sorted by relevance

12345678910>>...47

/OK3568_Linux_fs/kernel/drivers/scsi/sym53c8xx_2/
H A Dsym_nvram.c21 * NVRAM detection and reading.
35 * Get host setup from NVRAM.
37 void sym_nvram_setup_host(struct Scsi_Host *shost, struct sym_hcb *np, struct sym_nvram *nvram) in sym_nvram_setup_host() argument
41 * and miscellaneous host flags from NVRAM. in sym_nvram_setup_host()
43 switch (nvram->type) { in sym_nvram_setup_host()
45 if (!(nvram->data.Symbios.flags & SYMBIOS_PARITY_ENABLE)) in sym_nvram_setup_host()
47 np->myaddr = nvram->data.Symbios.host_id & 0x0f; in sym_nvram_setup_host()
48 if (nvram->data.Symbios.flags & SYMBIOS_VERBOSE_MSGS) in sym_nvram_setup_host()
50 if (nvram->data.Symbios.flags1 & SYMBIOS_SCAN_HI_LO) in sym_nvram_setup_host()
52 if (nvram->data.Symbios.flags2 & SYMBIOS_AVOID_BUS_RESET) in sym_nvram_setup_host()
[all …]
H A Dsym_nvram.h21 * NVRAM detection and reading.
33 * Symbios NVRAM data format
124 * Tekram NvRAM data format.
166 * Union of supported NVRAM formats.
183 void sym_nvram_setup_host(struct Scsi_Host *shost, struct sym_hcb *np, struct sym_nvram *nvram);
188 …void sym_nvram_setup_host(struct Scsi_Host *shost, struct sym_hcb *np, struct sym_nvram *nvram) { } in sym_nvram_setup_host() argument
189 static inline void sym_nvram_setup_target(struct sym_tcb *tp, struct sym_nvram *nvram) { } in sym_nvram_setup_target() argument
197 return "No NVRAM"; in sym_nvram_type()
/OK3568_Linux_fs/kernel/include/linux/
H A Dbcm963xx_nvram.h11 * Broadcom BCM963xx SoC board nvram data structure.
13 * The nvram structure varies in size depending on the SoC board version. Use
51 #define BCM963XX_NVRAM_NAND_PART_OFFSET(nvram, part) \ argument
52 bcm963xx_nvram_nand_part_offset(nvram, BCM963XX_NVRAM_NAND_PART_ ##part)
55 const struct bcm963xx_nvram *nvram, in bcm963xx_nvram_nand_part_offset() argument
58 return nvram->nand_part_offset[part] * SZ_1K; in bcm963xx_nvram_nand_part_offset()
61 #define BCM963XX_NVRAM_NAND_PART_SIZE(nvram, part) \ argument
62 bcm963xx_nvram_nand_part_size(nvram, BCM963XX_NVRAM_NAND_PART_ ##part)
65 const struct bcm963xx_nvram *nvram, in bcm963xx_nvram_nand_part_size() argument
68 return nvram->nand_part_size[part] * SZ_1K; in bcm963xx_nvram_nand_part_size()
[all …]
H A Dnvram.h6 #include <uapi/linux/nvram.h>
13 * struct nvram_ops - NVRAM functionality made available to drivers
14 * @read: validate checksum (if any) then load a range of bytes from NVRAM
15 * @write: store a range of bytes to NVRAM then update checksum (if any)
16 * @read_byte: load a single byte from NVRAM
17 * @write_byte: store a single byte to NVRAM
18 * @get_size: return the fixed number of bytes in the NVRAM
20 * Architectures which provide an nvram ops struct need not implement all
21 * of these methods. If the NVRAM hardware can be accessed only one byte
23 * If the NVRAM has a checksum (and it is to be checked) the .read and
/OK3568_Linux_fs/kernel/drivers/char/
H A Dnvram.c12 * "NVRAM" (NV stands for non-volatile).
14 * The data are supplied as a (seekable) character device, /dev/nvram. The
19 * Checksums over the NVRAM contents are managed by this driver. In case of a
21 * to a sane state either by ioctl(NVRAM_INIT) (clear whole NVRAM) or
35 #include <linux/nvram.h>
53 #include <asm/nvram.h>
71 * purpose memory in the NVRAM - that is to say, they all add the
72 * NVRAM_FIRST_BYTE offset. Pass them offsets into NVRAM as if you did not
219 * The are the file operation function for user access to /dev/nvram
288 pr_warn("nvram: Using obsolete PMAC_NVRAM_GET_OFFSET ioctl\n"); in nvram_misc_ioctl()
[all …]
/OK3568_Linux_fs/kernel/drivers/net/wireless/broadcom/brcm80211/brcmfmac/
H A Dfirmware.c38 * @nvram: output buffer with parse result.
46 * @boardrev_found: nvram contains boardrev information.
51 u8 *nvram; member
63 * is_nvram_char() - check if char is a valid one for NVRAM entry
152 memcpy(&nvp->nvram[nvp->nvram_len], skv, cplen); in brcmf_nvram_handle_value()
154 nvp->nvram[nvp->nvram_len] = '\0'; in brcmf_nvram_handle_value()
214 nvp->nvram = kzalloc(size, GFP_KERNEL); in brcmf_init_nvram_parser()
215 if (!nvp->nvram) in brcmf_init_nvram_parser()
223 /* brcmf_fw_strip_multi_v1 :Some nvram files contain settings for multiple
225 * which data is to be returned. v1 is the version where nvram is stored
[all …]
/OK3568_Linux_fs/kernel/arch/m68k/atari/
H A Dnvram.c3 * CMOS/NV-RAM driver for Atari. Adapted from drivers/char/nvram.c.
15 #include <linux/nvram.h>
26 * purpose memory in the NVRAM - that is to say, they all add the
27 * NVRAM_FIRST_BYTE offset. Pass them offsets into NVRAM as if you did not
178 static void atari_nvram_proc_read(unsigned char *nvram, struct seq_file *seq, in atari_nvram_proc_read() argument
193 if (nvram[1] == boot_prefs[i].val) { in atari_nvram_proc_read()
198 seq_printf(seq, "0x%02x (undefined)\n", nvram[1]); in atari_nvram_proc_read()
201 (nvram[16] & 0x80) ? "on" : "off"); in atari_nvram_proc_read()
203 if (nvram[16] & 0x80) in atari_nvram_proc_read()
204 seq_printf(seq, "%d\n", nvram[16] & 7); in atari_nvram_proc_read()
[all …]
/OK3568_Linux_fs/kernel/drivers/rtc/
H A Dnvmem.c46 rtc->nvram = kzalloc(sizeof(*rtc->nvram), GFP_KERNEL); in rtc_nvram_register()
47 if (!rtc->nvram) in rtc_nvram_register()
50 rtc->nvram->attr.name = "nvram"; in rtc_nvram_register()
51 rtc->nvram->attr.mode = 0644; in rtc_nvram_register()
52 rtc->nvram->private = nvmem; in rtc_nvram_register()
54 sysfs_bin_attr_init(rtc->nvram); in rtc_nvram_register()
56 rtc->nvram->read = rtc_nvram_read; in rtc_nvram_register()
57 rtc->nvram->write = rtc_nvram_write; in rtc_nvram_register()
58 rtc->nvram->size = size; in rtc_nvram_register()
61 rtc->nvram); in rtc_nvram_register()
[all …]
/OK3568_Linux_fs/kernel/drivers/net/wireless/rockchip_wlan/cywdhd/bcmdhd/include/
H A Dbcmnvram.h2 * NVRAM variable manipulation
55 * Get default value for an NVRAM variable
69 * Initialize NVRAM access. May be unnecessary or undefined on certain
78 * Append a chunk of nvram variables to the global list
90 * Disable NVRAM access. May be unnecessary or undefined on certain
96 * Get the value of an NVRAM variable. The pointer returned may be
104 * Get the value of an NVRAM variable. The pointer returned may be
113 * Read the reset GPIO value from the nvram and set the GPIO
119 * Get the value of an NVRAM variable.
131 * Match an NVRAM variable.
[all …]
/OK3568_Linux_fs/kernel/drivers/net/wireless/rockchip_wlan/infineon/bcmdhd/include/
H A Dbcmnvram.h2 * NVRAM variable manipulation
55 * Get default value for an NVRAM variable
69 * Initialize NVRAM access. May be unnecessary or undefined on certain
78 * Append a chunk of nvram variables to the global list
90 * Disable NVRAM access. May be unnecessary or undefined on certain
96 * Get the value of an NVRAM variable. The pointer returned may be
104 * Get the value of an NVRAM variable. The pointer returned may be
113 * Read the reset GPIO value from the nvram and set the GPIO
119 * Get the value of an NVRAM variable.
131 * Match an NVRAM variable.
[all …]
/OK3568_Linux_fs/external/rkwifibt/drivers/infineon/include/
H A Dbcmnvram.h2 * NVRAM variable manipulation
55 * Get default value for an NVRAM variable
69 * Initialize NVRAM access. May be unnecessary or undefined on certain
78 * Append a chunk of nvram variables to the global list
90 * Disable NVRAM access. May be unnecessary or undefined on certain
96 * Get the value of an NVRAM variable. The pointer returned may be
104 * Get the value of an NVRAM variable. The pointer returned may be
113 * Read the reset GPIO value from the nvram and set the GPIO
119 * Get the value of an NVRAM variable.
131 * Match an NVRAM variable.
[all …]
/OK3568_Linux_fs/kernel/drivers/net/wireless/rockchip_wlan/rkwifi/bcmdhd_indep_power/include/
H A Dbcmnvram.h3 * NVRAM variable manipulation
54 * Get default value for an NVRAM variable
68 * Initialize NVRAM access. May be unnecessary or undefined on certain
76 * Append a chunk of nvram variables to the global list
89 * Disable NVRAM access. May be unnecessary or undefined on certain
95 * Get the value of an NVRAM variable. The pointer returned may be
103 * Get the value of an NVRAM variable. The pointer returned may be
112 * Read the reset GPIO value from the nvram and set the GPIO
118 * Get the value of an NVRAM variable.
130 * Match an NVRAM variable.
[all …]
/OK3568_Linux_fs/kernel/drivers/mtd/parsers/
H A Dbcm63xxpart.c52 struct bcm963xx_nvram *nvram) in bcm63xx_read_nvram() argument
58 /* extract nvram data */ in bcm63xx_read_nvram()
60 &retlen, (void *)nvram); in bcm63xx_read_nvram()
64 ret = bcm963xx_nvram_checksum(nvram, &expected_crc, &actual_crc); in bcm63xx_read_nvram()
66 pr_warn("nvram checksum failed, contents may be invalid (expected %08x, got %08x)\n", in bcm63xx_read_nvram()
69 if (!nvram->psi_size) in bcm63xx_read_nvram()
70 nvram->psi_size = BCM963XX_DEFAULT_PSI_SIZE; in bcm63xx_read_nvram()
81 const struct mtd_partition **pparts, struct bcm963xx_nvram *nvram) in bcm63xx_parse_cfe_nor_partitions() argument
93 nvramlen = nvram->psi_size * SZ_1K; in bcm63xx_parse_cfe_nor_partitions()
106 parts[curpart].name = "nvram"; in bcm63xx_parse_cfe_nor_partitions()
[all …]
/OK3568_Linux_fs/kernel/arch/mips/bcm63xx/
H A Dnvram.c24 static struct bcm963xx_nvram nvram; variable
32 /* extract nvram data */ in bcm63xx_nvram_init()
33 memcpy(&nvram, addr, BCM963XX_NVRAM_V5_SIZE); in bcm63xx_nvram_init()
36 if (bcm963xx_nvram_checksum(&nvram, &expected_crc, &crc)) in bcm63xx_nvram_init()
37 pr_warn("nvram checksum failed, contents may be invalid (expected %08x, got %08x)\n", in bcm63xx_nvram_init()
40 /* Cable modems have a different NVRAM which is embedded in the eCos in bcm63xx_nvram_init()
45 memcpy(nvram.mac_addr_base, hcs_mac_addr, ETH_ALEN); in bcm63xx_nvram_init()
46 nvram.mac_addr_count = 2; in bcm63xx_nvram_init()
52 return nvram.name; in bcm63xx_nvram_get_name()
61 if (mac_addr_used >= nvram.mac_addr_count) { in bcm63xx_nvram_get_mac_address()
[all …]
/OK3568_Linux_fs/kernel/drivers/firmware/broadcom/
H A Dbcm47xx_nvram.c3 * BCM947xx nvram variable access
51 /* Probe for NVRAM header */
59 pr_warn("nvram already initialized\n"); in nvram_find_and_copy()
63 /* TODO: when nvram is on nand flash check for bad blocks first. */ in nvram_find_and_copy()
75 /* Try embedded NVRAM at 4 KB and 1 KB as last resorts */ in nvram_find_and_copy()
88 pr_err("no nvram found\n"); in nvram_find_and_copy()
95 pr_err("The nvram size according to the header seems to be bigger than the partition on flash\n"); in nvram_find_and_copy()
99 …pr_err("nvram on flash (%zu bytes) is bigger than the reserved space in memory, will just copy the… in nvram_find_and_copy()
112 * On bcm47xx we need access to the NVRAM very early, so we can't use mtd
116 * soon as we get info about flash device, before any NVRAM entry is needed.
[all …]
/OK3568_Linux_fs/external/rkwifibt/drivers/bcmdhd/include/
H A Dbcmnvram.h2 * NVRAM variable manipulation
49 * Initialize NVRAM access. May be unnecessary or undefined on certain
57 * Append a chunk of nvram variables to the global list
67 * Disable NVRAM access. May be unnecessary or undefined on certain
73 * Get the value of an NVRAM variable. The pointer returned may be
81 * Get the value of an NVRAM variable.
93 * Set the value of an NVRAM variable. The name and value strings are
104 * Unset an NVRAM variable. Pointers to previously set values
113 * Commit NVRAM variables to permanent storage. All pointers to values
115 * NVRAM values are undefined after a commit.
[all …]
/OK3568_Linux_fs/kernel/drivers/net/wireless/rockchip_wlan/rkwifi/bcmdhd/include/
H A Dbcmnvram.h2 * NVRAM variable manipulation
49 * Initialize NVRAM access. May be unnecessary or undefined on certain
57 * Append a chunk of nvram variables to the global list
67 * Disable NVRAM access. May be unnecessary or undefined on certain
73 * Get the value of an NVRAM variable. The pointer returned may be
81 * Get the value of an NVRAM variable.
93 * Set the value of an NVRAM variable. The name and value strings are
104 * Unset an NVRAM variable. Pointers to previously set values
113 * Commit NVRAM variables to permanent storage. All pointers to values
115 * NVRAM values are undefined after a commit.
[all …]
/OK3568_Linux_fs/kernel/arch/powerpc/platforms/pseries/
H A Dnvram.c5 * /dev/nvram driver for PPC64
16 #include <asm/nvram.h>
130 * We need to buffer the error logs into nvram to ensure that we have
150 * Reads nvram for error log for at most 'length'
203 /* Scan nvram for partitions */ in pseries_nvram_init_log_partitions()
214 struct device_node *nvram; in pSeries_nvram_init() local
218 nvram = of_find_node_by_type(NULL, "nvram"); in pSeries_nvram_init()
219 if (nvram == NULL) in pSeries_nvram_init()
222 nbytes_p = of_get_property(nvram, "#bytes", &proplen); in pSeries_nvram_init()
224 of_node_put(nvram); in pSeries_nvram_init()
[all …]
/OK3568_Linux_fs/kernel/arch/powerpc/platforms/chrp/
H A Dnvram.c5 * /dev/nvram driver for PPC
34 if ((rtas_call(rtas_token("nvram-fetch"), 3, 2, &done, addr, in chrp_nvram_read_val()
56 if ((rtas_call(rtas_token("nvram-store"), 3, 2, &done, addr, in chrp_nvram_write_val()
69 struct device_node *nvram; in chrp_nvram_init() local
73 nvram = of_find_node_by_type(NULL, "nvram"); in chrp_nvram_init()
74 if (nvram == NULL) in chrp_nvram_init()
77 nbytes_p = of_get_property(nvram, "#bytes", &proplen); in chrp_nvram_init()
79 of_node_put(nvram); in chrp_nvram_init()
85 printk(KERN_INFO "CHRP nvram contains %u bytes\n", nvram_size); in chrp_nvram_init()
86 of_node_put(nvram); in chrp_nvram_init()
/OK3568_Linux_fs/kernel/arch/powerpc/platforms/powermac/
H A Dnvram.c11 #include <linux/nvram.h>
24 #include <asm/nvram.h>
41 /* On Core99, nvram is either a sharp, a micron or an AMD flash */
52 /* CHRP NVRAM header */
287 DBG("nvram: Sharp/Micron Erasing bank %d...\n", bank); in sm_erase_bank()
294 printk(KERN_ERR "nvram: Sharp/Micron flash erase timeout !\n"); in sm_erase_bank()
305 printk(KERN_ERR "nvram: Sharp/Micron flash erase failed !\n"); in sm_erase_bank()
318 DBG("nvram: Sharp/Micron Writing bank %d...\n", bank); in sm_write_bank()
327 printk(KERN_ERR "nvram: Sharp/Micron flash write timeout !\n"); in sm_write_bank()
339 printk(KERN_ERR "nvram: Sharp/Micron flash write failed !\n"); in sm_write_bank()
[all …]
/OK3568_Linux_fs/kernel/arch/mips/include/asm/mach-bcm63xx/
H A Dbcm63xx_nvram.h8 * bcm63xx_nvram_init() - initializes nvram
9 * @nvram: address of the nvram data
11 * Initialized the local nvram copy from the target address and checks
14 void bcm63xx_nvram_init(void *nvram);
17 * bcm63xx_nvram_get_name() - returns the board name according to nvram
19 * Returns the board name field from nvram. Note that it might not be
28 * Registers and returns a mac address from the allocated macs from nvram.
/OK3568_Linux_fs/kernel/arch/powerpc/sysdev/
H A Dmmio_nvram.c3 * memory mapped NVRAM
17 #include <asm/nvram.h>
104 nvram_node = of_find_node_by_type(NULL, "nvram"); in mmio_nvram_init()
106 nvram_node = of_find_compatible_node(NULL, NULL, "nvram"); in mmio_nvram_init()
108 printk(KERN_WARNING "nvram: no node found in device-tree\n"); in mmio_nvram_init()
114 printk(KERN_WARNING "nvram: failed to get address (err %d)\n", in mmio_nvram_init()
121 printk(KERN_WARNING "nvram: address or length is 0\n"); in mmio_nvram_init()
128 printk(KERN_WARNING "nvram: failed to ioremap\n"); in mmio_nvram_init()
133 printk(KERN_INFO "mmio NVRAM, %luk at 0x%lx mapped to %p\n", in mmio_nvram_init()
/OK3568_Linux_fs/kernel/arch/powerpc/kernel/
H A Dnvram_64.c5 * /dev/nvram driver for PPC64
13 #include <linux/nvram.h>
22 #include <asm/nvram.h>
91 * holding the timestamp. oops_buf[] gets written to NVRAM.
153 * We need to buffer the error logs into nvram to ensure that we have
160 * captured to disk, thus we buffer it in NVRAM for analysis on the
163 * In NVRAM the partition containing the error log buffer will looks like:
217 * Reads nvram partition for at most 'length'
284 pr_info("nvram: Found too small %s partition," in nvram_init_os_partition()
295 pr_info("nvram: No room to create %s partition, " in nvram_init_os_partition()
[all …]
/OK3568_Linux_fs/kernel/arch/powerpc/include/asm/
H A Dnvram.h3 * NVRAM definitions and access functions.
11 #include <uapi/asm/nvram.h>
70 /* Return partition offset in nvram */
77 /* Initialize NVRAM OS partition */
80 /* Initialize NVRAM oops partition */
83 /* Read a NVRAM partition */
88 /* Write to NVRAM OS partition */
/OK3568_Linux_fs/kernel/arch/powerpc/include/uapi/asm/
H A Dnvram.h3 * NVRAM definitions and access functions.
14 /* Signatures for nvram partitions */
30 /* PowerMac specific nvram stuffs */
51 * /dev/nvram ioctls
60 #define IOC_NVRAM_GET_OFFSET _IOWR('p', 0x42, int) /* Get NVRAM partition offset */
61 #define IOC_NVRAM_SYNC _IO('p', 0x43) /* Sync NVRAM image */

12345678910>>...47