Home
last modified time | relevance | path

Searched full:map (Results 1 – 25 of 7564) sorted by relevance

12345678910>>...303

/kernel/linux/linux-5.10/drivers/base/regmap/
Dregcache.c26 static int regcache_hw_init(struct regmap *map) in regcache_hw_init() argument
34 if (!map->num_reg_defaults_raw) in regcache_hw_init()
38 for (count = 0, i = 0; i < map->num_reg_defaults_raw; i++) in regcache_hw_init()
39 if (regmap_readable(map, i * map->reg_stride) && in regcache_hw_init()
40 !regmap_volatile(map, i * map->reg_stride)) in regcache_hw_init()
45 map->cache_bypass = true; in regcache_hw_init()
49 map->num_reg_defaults = count; in regcache_hw_init()
50 map->reg_defaults = kmalloc_array(count, sizeof(struct reg_default), in regcache_hw_init()
52 if (!map->reg_defaults) in regcache_hw_init()
55 if (!map->reg_defaults_raw) { in regcache_hw_init()
[all …]
Dregmap.c3 // Register map access API
36 static inline bool regmap_should_log(struct regmap *map) in regmap_should_log() argument
38 return (map->dev && strcmp(dev_name(map->dev), LOG_DEVICE) == 0); in regmap_should_log()
41 static inline bool regmap_should_log(struct regmap *map) { return false; } in regmap_should_log() argument
45 static int _regmap_update_bits(struct regmap *map, unsigned int reg,
74 bool regmap_check_range_table(struct regmap *map, unsigned int reg, in regmap_check_range_table() argument
90 bool regmap_writeable(struct regmap *map, unsigned int reg) in regmap_writeable() argument
92 if (map->max_register && reg > map->max_register) in regmap_writeable()
95 if (map->writeable_reg) in regmap_writeable()
96 return map->writeable_reg(map->dev, reg); in regmap_writeable()
[all …]
Dregmap-debugfs.c3 // Register map access API - debugfs
19 struct regmap *map; member
38 struct regmap *map = file->private_data; in regmap_name_read_file() local
47 if (map->dev && map->dev->driver) in regmap_name_read_file()
48 name = map->dev->driver->name; in regmap_name_read_file()
67 static void regmap_debugfs_free_dump_cache(struct regmap *map) in regmap_debugfs_free_dump_cache() argument
71 while (!list_empty(&map->debugfs_off_cache)) { in regmap_debugfs_free_dump_cache()
72 c = list_first_entry(&map->debugfs_off_cache, in regmap_debugfs_free_dump_cache()
80 static bool regmap_printable(struct regmap *map, unsigned int reg) in regmap_printable() argument
82 if (regmap_precious(map, reg)) in regmap_printable()
[all …]
/kernel/linux/linux-4.19/drivers/base/regmap/
Dregcache.c30 static int regcache_hw_init(struct regmap *map) in regcache_hw_init() argument
38 if (!map->num_reg_defaults_raw) in regcache_hw_init()
42 for (count = 0, i = 0; i < map->num_reg_defaults_raw; i++) in regcache_hw_init()
43 if (regmap_readable(map, i * map->reg_stride) && in regcache_hw_init()
44 !regmap_volatile(map, i * map->reg_stride)) in regcache_hw_init()
49 map->cache_bypass = true; in regcache_hw_init()
53 map->num_reg_defaults = count; in regcache_hw_init()
54 map->reg_defaults = kmalloc_array(count, sizeof(struct reg_default), in regcache_hw_init()
56 if (!map->reg_defaults) in regcache_hw_init()
59 if (!map->reg_defaults_raw) { in regcache_hw_init()
[all …]
Dregmap.c2 * Register map access API
39 static int _regmap_update_bits(struct regmap *map, unsigned int reg,
68 bool regmap_check_range_table(struct regmap *map, unsigned int reg, in regmap_check_range_table() argument
84 bool regmap_writeable(struct regmap *map, unsigned int reg) in regmap_writeable() argument
86 if (map->max_register && reg > map->max_register) in regmap_writeable()
89 if (map->writeable_reg) in regmap_writeable()
90 return map->writeable_reg(map->dev, reg); in regmap_writeable()
92 if (map->wr_table) in regmap_writeable()
93 return regmap_check_range_table(map, reg, map->wr_table); in regmap_writeable()
98 bool regmap_cached(struct regmap *map, unsigned int reg) in regmap_cached() argument
[all …]
Dregmap-debugfs.c2 * Register map access API - debugfs
23 struct regmap *map; member
43 struct regmap *map = file->private_data; in regmap_name_read_file() local
52 if (map->dev && map->dev->driver) in regmap_name_read_file()
53 name = map->dev->driver->name; in regmap_name_read_file()
72 static void regmap_debugfs_free_dump_cache(struct regmap *map) in regmap_debugfs_free_dump_cache() argument
76 while (!list_empty(&map->debugfs_off_cache)) { in regmap_debugfs_free_dump_cache()
77 c = list_first_entry(&map->debugfs_off_cache, in regmap_debugfs_free_dump_cache()
85 static bool regmap_printable(struct regmap *map, unsigned int reg) in regmap_printable() argument
87 if (regmap_precious(map, reg)) in regmap_printable()
[all …]
/kernel/linux/linux-4.19/tools/perf/util/
Dmap.h23 struct map { struct
41 u64 (*map_ip)(struct map *, u64); argument
43 u64 (*unmap_ip)(struct map *, u64); argument
82 struct kmap *__map__kmap(struct map *map);
83 struct kmap *map__kmap(struct map *map);
84 struct map_groups *map__kmaps(struct map *map);
86 static inline u64 map__map_ip(struct map *map, u64 ip) in map__map_ip() argument
88 return ip - map->start + map->pgoff; in map__map_ip()
91 static inline u64 map__unmap_ip(struct map *map, u64 ip) in map__unmap_ip() argument
93 return ip + map->start - map->pgoff; in map__unmap_ip()
[all …]
Dmap.c12 #include "map.h"
24 static void __maps__insert(struct maps *maps, struct map *map);
128 void map__init(struct map *map, u64 start, u64 end, u64 pgoff, struct dso *dso) in map__init() argument
130 map->start = start; in map__init()
131 map->end = end; in map__init()
132 map->pgoff = pgoff; in map__init()
133 map->reloc = 0; in map__init()
134 map->dso = dso__get(dso); in map__init()
135 map->map_ip = map__map_ip; in map__init()
136 map->unmap_ip = map__unmap_ip; in map__init()
[all …]
/kernel/linux/linux-5.10/tools/perf/util/
Dmap.h18 struct map { struct
32 u64 (*map_ip)(struct map *, u64); argument
34 u64 (*unmap_ip)(struct map *, u64); argument
43 struct kmap *__map__kmap(struct map *map); argument
44 struct kmap *map__kmap(struct map *map);
45 struct maps *map__kmaps(struct map *map);
47 static inline u64 map__map_ip(struct map *map, u64 ip) in map__map_ip() argument
49 return ip - map->start + map->pgoff; in map__map_ip()
52 static inline u64 map__unmap_ip(struct map *map, u64 ip) in map__unmap_ip() argument
54 return ip + map->start - map->pgoff; in map__unmap_ip()
[all …]
Dmap.c13 #include "map.h"
28 static void __maps__insert(struct maps *maps, struct map *map);
116 void map__init(struct map *map, u64 start, u64 end, u64 pgoff, struct dso *dso) in map__init() argument
118 map->start = start; in map__init()
119 map->end = end; in map__init()
120 map->pgoff = pgoff; in map__init()
121 map->reloc = 0; in map__init()
122 map->dso = dso__get(dso); in map__init()
123 map->map_ip = map__map_ip; in map__init()
124 map->unmap_ip = map__unmap_ip; in map__init()
[all …]
Dhashmap.c4 * Generic non-thread safe hash map implementation.
38 void hashmap__init(struct hashmap *map, hashmap_hash_fn hash_fn, in hashmap__init() argument
41 map->hash_fn = hash_fn; in hashmap__init()
42 map->equal_fn = equal_fn; in hashmap__init()
43 map->ctx = ctx; in hashmap__init()
45 map->buckets = NULL; in hashmap__init()
46 map->cap = 0; in hashmap__init()
47 map->cap_bits = 0; in hashmap__init()
48 map->sz = 0; in hashmap__init()
55 struct hashmap *map = malloc(sizeof(struct hashmap)); in hashmap__new() local
[all …]
Dmmap.c39 size_t mmap__mmap_len(struct mmap *map) in mmap__mmap_len() argument
41 return perf_mmap__mmap_len(&map->core); in mmap__mmap_len()
71 static int perf_mmap__aio_enabled(struct mmap *map) in perf_mmap__aio_enabled() argument
73 return map->aio.nr_cblocks > 0; in perf_mmap__aio_enabled()
77 static int perf_mmap__aio_alloc(struct mmap *map, int idx) in perf_mmap__aio_alloc() argument
79 map->aio.data[idx] = mmap(NULL, mmap__mmap_len(map), PROT_READ|PROT_WRITE, in perf_mmap__aio_alloc()
81 if (map->aio.data[idx] == MAP_FAILED) { in perf_mmap__aio_alloc()
82 map->aio.data[idx] = NULL; in perf_mmap__aio_alloc()
89 static void perf_mmap__aio_free(struct mmap *map, int idx) in perf_mmap__aio_free() argument
91 if (map->aio.data[idx]) { in perf_mmap__aio_free()
[all …]
/kernel/linux/linux-5.10/include/linux/mtd/
Dmap.h22 #define map_bankwidth(map) 1 argument
23 #define map_bankwidth_is_1(map) (map_bankwidth(map) == 1) argument
24 #define map_bankwidth_is_large(map) (0) argument
25 #define map_words(map) (1) argument
28 #define map_bankwidth_is_1(map) (0) argument
34 # define map_bankwidth(map) ((map)->bankwidth) argument
36 # define map_bankwidth(map) 2 argument
37 # define map_bankwidth_is_large(map) (0) argument
38 # define map_words(map) (1) argument
40 #define map_bankwidth_is_2(map) (map_bankwidth(map) == 2) argument
[all …]
/kernel/linux/linux-4.19/include/linux/mtd/
Dmap.h36 #define map_bankwidth(map) 1 argument
37 #define map_bankwidth_is_1(map) (map_bankwidth(map) == 1) argument
38 #define map_bankwidth_is_large(map) (0) argument
39 #define map_words(map) (1) argument
42 #define map_bankwidth_is_1(map) (0) argument
48 # define map_bankwidth(map) ((map)->bankwidth) argument
50 # define map_bankwidth(map) 2 argument
51 # define map_bankwidth_is_large(map) (0) argument
52 # define map_words(map) (1) argument
54 #define map_bankwidth_is_2(map) (map_bankwidth(map) == 2) argument
[all …]
/kernel/linux/linux-5.10/drivers/mtd/maps/
Dpci.c7 * Generic PCI memory map driver. We support the following boards:
17 #include <linux/mtd/map.h>
23 int (*init)(struct pci_dev *dev, struct map_pci_info *map);
24 void (*exit)(struct pci_dev *dev, struct map_pci_info *map);
25 unsigned long (*translate)(struct map_pci_info *map, unsigned long ofs);
30 struct map_info map; member
32 void (*exit)(struct pci_dev *dev, struct map_pci_info *map);
33 unsigned long (*translate)(struct map_pci_info *map, unsigned long ofs);
39 struct map_pci_info *map = (struct map_pci_info *)_map; in mtd_pci_read8() local
41 val.x[0]= readb(map->base + map->translate(map, ofs)); in mtd_pci_read8()
[all …]
Damd76xrom.c15 #include <linux/mtd/map.h>
42 struct map_info map; member
71 struct amd76xrom_map_info *map, *scratch; in amd76xrom_cleanup() local
82 list_for_each_entry_safe(map, scratch, &window->maps, list) { in amd76xrom_cleanup()
83 if (map->rsrc.parent) { in amd76xrom_cleanup()
84 release_resource(&map->rsrc); in amd76xrom_cleanup()
86 mtd_device_unregister(map->mtd); in amd76xrom_cleanup()
87 map_destroy(map->mtd); in amd76xrom_cleanup()
88 list_del(&map->list); in amd76xrom_cleanup()
89 kfree(map); in amd76xrom_cleanup()
[all …]
/kernel/linux/linux-4.19/drivers/mtd/maps/
Dpci.c10 * Generic PCI memory map driver. We support the following boards:
20 #include <linux/mtd/map.h>
26 int (*init)(struct pci_dev *dev, struct map_pci_info *map);
27 void (*exit)(struct pci_dev *dev, struct map_pci_info *map);
28 unsigned long (*translate)(struct map_pci_info *map, unsigned long ofs);
33 struct map_info map; member
35 void (*exit)(struct pci_dev *dev, struct map_pci_info *map);
36 unsigned long (*translate)(struct map_pci_info *map, unsigned long ofs);
42 struct map_pci_info *map = (struct map_pci_info *)_map; in mtd_pci_read8() local
44 val.x[0]= readb(map->base + map->translate(map, ofs)); in mtd_pci_read8()
[all …]
Damd76xrom.c14 #include <linux/mtd/map.h>
41 struct map_info map; member
70 struct amd76xrom_map_info *map, *scratch; in amd76xrom_cleanup() local
81 list_for_each_entry_safe(map, scratch, &window->maps, list) { in amd76xrom_cleanup()
82 if (map->rsrc.parent) { in amd76xrom_cleanup()
83 release_resource(&map->rsrc); in amd76xrom_cleanup()
85 mtd_device_unregister(map->mtd); in amd76xrom_cleanup()
86 map_destroy(map->mtd); in amd76xrom_cleanup()
87 list_del(&map->list); in amd76xrom_cleanup()
88 kfree(map); in amd76xrom_cleanup()
[all …]
/kernel/linux/linux-4.19/net/sctp/
Dtsnmap.c44 static void sctp_tsnmap_update(struct sctp_tsnmap *map);
45 static void sctp_tsnmap_find_gap_ack(unsigned long *map, __u16 off,
47 static int sctp_tsnmap_grow(struct sctp_tsnmap *map, u16 size);
50 struct sctp_tsnmap *sctp_tsnmap_init(struct sctp_tsnmap *map, __u16 len, in sctp_tsnmap_init() argument
53 if (!map->tsn_map) { in sctp_tsnmap_init()
54 map->tsn_map = kzalloc(len>>3, gfp); in sctp_tsnmap_init()
55 if (map->tsn_map == NULL) in sctp_tsnmap_init()
58 map->len = len; in sctp_tsnmap_init()
60 bitmap_zero(map->tsn_map, map->len); in sctp_tsnmap_init()
64 map->base_tsn = initial_tsn; in sctp_tsnmap_init()
[all …]
/kernel/linux/linux-5.10/net/sctp/
Dtsnmap.c29 static void sctp_tsnmap_update(struct sctp_tsnmap *map);
30 static void sctp_tsnmap_find_gap_ack(unsigned long *map, __u16 off,
32 static int sctp_tsnmap_grow(struct sctp_tsnmap *map, u16 size);
35 struct sctp_tsnmap *sctp_tsnmap_init(struct sctp_tsnmap *map, __u16 len, in sctp_tsnmap_init() argument
38 if (!map->tsn_map) { in sctp_tsnmap_init()
39 map->tsn_map = kzalloc(len>>3, gfp); in sctp_tsnmap_init()
40 if (map->tsn_map == NULL) in sctp_tsnmap_init()
43 map->len = len; in sctp_tsnmap_init()
45 bitmap_zero(map->tsn_map, map->len); in sctp_tsnmap_init()
49 map->base_tsn = initial_tsn; in sctp_tsnmap_init()
[all …]
/kernel/linux/linux-5.10/tools/lib/bpf/
Dhashmap.c4 * Generic non-thread safe hash map implementation.
38 void hashmap__init(struct hashmap *map, hashmap_hash_fn hash_fn, in hashmap__init() argument
41 map->hash_fn = hash_fn; in hashmap__init()
42 map->equal_fn = equal_fn; in hashmap__init()
43 map->ctx = ctx; in hashmap__init()
45 map->buckets = NULL; in hashmap__init()
46 map->cap = 0; in hashmap__init()
47 map->cap_bits = 0; in hashmap__init()
48 map->sz = 0; in hashmap__init()
55 struct hashmap *map = malloc(sizeof(struct hashmap)); in hashmap__new() local
[all …]
/kernel/linux/linux-5.10/tools/lib/perf/
Dmmap.c16 void perf_mmap__init(struct perf_mmap *map, struct perf_mmap *prev, in perf_mmap__init() argument
19 map->fd = -1; in perf_mmap__init()
20 map->overwrite = overwrite; in perf_mmap__init()
21 map->unmap_cb = unmap_cb; in perf_mmap__init()
22 refcount_set(&map->refcnt, 0); in perf_mmap__init()
24 prev->next = map; in perf_mmap__init()
27 size_t perf_mmap__mmap_len(struct perf_mmap *map) in perf_mmap__mmap_len() argument
29 return map->mask + 1 + page_size; in perf_mmap__mmap_len()
32 int perf_mmap__mmap(struct perf_mmap *map, struct perf_mmap_param *mp, in perf_mmap__mmap() argument
35 map->prev = 0; in perf_mmap__mmap()
[all …]
/kernel/linux/linux-4.19/kernel/bpf/
Dlocal_storage.c18 struct bpf_map map; member
26 static struct bpf_cgroup_storage_map *map_to_storage(struct bpf_map *map) in map_to_storage() argument
28 return container_of(map, struct bpf_cgroup_storage_map, map); in map_to_storage()
47 struct bpf_cgroup_storage_map *map, struct bpf_cgroup_storage_key *key, in cgroup_storage_lookup() argument
50 struct rb_root *root = &map->root; in cgroup_storage_lookup()
54 spin_lock_bh(&map->lock); in cgroup_storage_lookup()
71 spin_unlock_bh(&map->lock); in cgroup_storage_lookup()
77 spin_unlock_bh(&map->lock); in cgroup_storage_lookup()
82 static int cgroup_storage_insert(struct bpf_cgroup_storage_map *map, in cgroup_storage_insert() argument
85 struct rb_root *root = &map->root; in cgroup_storage_insert()
[all …]
/kernel/linux/linux-5.10/tools/bpf/bpftool/Documentation/
Dbpftool-map.rst2 bpftool-map
13 **bpftool** [*OPTIONS*] **map** *COMMAND*
21 MAP COMMANDS
24 | **bpftool** **map** { **show** | **list** } [*MAP*]
25 | **bpftool** **map create** *FILE* **type** *TYPE* **key** *KEY_SIZE* **value** *VALUE_SIZE* \
26 | **entries** *MAX_ENTRIES* **name** *NAME* [**flags** *FLAGS*] [**inner_map** *MAP*] \
28 | **bpftool** **map dump** *MAP*
29 | **bpftool** **map update** *MAP* [**key** *DATA*] [**value** *VALUE*] [*UPDATE_FLAGS*]
30 | **bpftool** **map lookup** *MAP* [**key** *DATA*]
31 | **bpftool** **map getnext** *MAP* [**key** *DATA*]
[all …]
/kernel/linux/linux-5.10/drivers/mtd/lpddr/
Dqinfo_probe.c16 #include <linux/mtd/map.h>
20 static int lpddr_chip_setup(struct map_info *map, struct lpddr_private *lpddr);
21 struct mtd_info *lpddr_probe(struct map_info *map);
22 static struct lpddr_private *lpddr_probe_chip(struct map_info *map);
23 static int lpddr_pfow_present(struct map_info *map,
44 static long lpddr_get_qinforec_pos(struct map_info *map, char *id_str) in lpddr_get_qinforec_pos() argument
48 int bankwidth = map_bankwidth(map) * 8; in lpddr_get_qinforec_pos()
58 printk(KERN_ERR"%s qinfo id string is wrong! \n", map->name); in lpddr_get_qinforec_pos()
63 static uint16_t lpddr_info_query(struct map_info *map, char *id_str) in lpddr_info_query() argument
66 int bits_per_chip = map_bankwidth(map) * 8; in lpddr_info_query()
[all …]

12345678910>>...303