Home
last modified time | relevance | path

Searched full:ns (Results 1 – 25 of 2509) sorted by relevance

12345678910>>...101

/openbmc/qemu/hw/nvme/
H A Dns.c30 void nvme_ns_init_format(NvmeNamespace *ns) in nvme_ns_init_format() argument
32 NvmeIdNs *id_ns = &ns->id_ns; in nvme_ns_init_format()
33 NvmeIdNsNvm *id_ns_nvm = &ns->id_ns_nvm; in nvme_ns_init_format()
38 ns->lbaf = id_ns->lbaf[NVME_ID_NS_FLBAS_INDEX(id_ns->flbas)]; in nvme_ns_init_format()
39 ns->lbasz = 1 << ns->lbaf.ds; in nvme_ns_init_format()
41 nlbas = ns->size / (ns->lbasz + ns->lbaf.ms); in nvme_ns_init_format()
49 ns->moff = nlbas << ns->lbaf.ds; in nvme_ns_init_format()
51 npdg = ns->blkconf.discard_granularity / ns->lbasz; in nvme_ns_init_format()
53 ret = bdrv_get_info(blk_bs(ns->blkconf.blk), &bdi); in nvme_ns_init_format()
54 if (ret >= 0 && bdi.cluster_size > ns->blkconf.discard_granularity) { in nvme_ns_init_format()
[all …]
H A Ddif.c19 uint16_t nvme_check_prinfo(NvmeNamespace *ns, uint8_t prinfo, uint64_t slba, in nvme_check_prinfo() argument
22 uint64_t mask = ns->pif ? 0xffffffffffff : 0xffffffff; in nvme_check_prinfo()
24 if ((NVME_ID_NS_DPS_TYPE(ns->id_ns.dps) == NVME_ID_NS_DPS_TYPE_1) && in nvme_check_prinfo()
29 if ((NVME_ID_NS_DPS_TYPE(ns->id_ns.dps) == NVME_ID_NS_DPS_TYPE_3) && in nvme_check_prinfo()
63 static void nvme_dif_pract_generate_dif_crc16(NvmeNamespace *ns, uint8_t *buf, in nvme_dif_pract_generate_dif_crc16() argument
71 if (!(ns->id_ns.dps & NVME_ID_NS_DPS_FIRST_EIGHT)) { in nvme_dif_pract_generate_dif_crc16()
72 pil = ns->lbaf.ms - nvme_pi_tuple_size(ns); in nvme_dif_pract_generate_dif_crc16()
75 trace_pci_nvme_dif_pract_generate_dif_crc16(len, ns->lbasz, in nvme_dif_pract_generate_dif_crc16()
76 ns->lbasz + pil, apptag, in nvme_dif_pract_generate_dif_crc16()
79 for (; buf < end; buf += ns->lbasz, mbuf += ns->lbaf.ms) { in nvme_dif_pract_generate_dif_crc16()
[all …]
/openbmc/linux/tools/testing/selftests/net/forwarding/
H A Dfib_offload_lib.sh7 local ns=$1; shift
13 ip -n $ns -j -p -$family route show $route \
29 local ns=$1; shift
34 busywait 5000 __fib_trap_check $ns $family "$route" $should_fail
39 local ns=$1; shift
43 fib_trap_check $ns 4 "$route" $should_fail
48 local ns=$1; shift
52 fib_trap_check $ns 6 "$route" $should_fail
57 local ns=$1; shift
63 ip -n $ns link add name dummy$i type dummy
[all …]
/openbmc/linux/drivers/mtd/nand/raw/
H A Dnandsim.c9 * Note: NS means "NAND Simulator".
189 #define NS_IS_INITIALIZED(ns) ((ns)->geom.totsz != 0) argument
192 #define NS_STATUS_OK(ns) (NAND_STATUS_READY | (NAND_STATUS_WP * ((ns)->lines.wp == 0))) argument
195 #define NS_STATUS_FAILED(ns) (NAND_STATUS_FAIL | NS_STATUS_OK(ns)) argument
198 #define NS_RAW_OFFSET(ns) \ argument
199 (((ns)->regs.row * (ns)->geom.pgszoob) + (ns)->regs.column)
202 #define NS_RAW_OFFSET_OOB(ns) (NS_RAW_OFFSET(ns) + ns->geom.pgsz) argument
205 #define NS_PAGE_BYTE_SHIFT(ns) ((ns)->regs.column + (ns)->regs.off) argument
491 DEFINE_SHOW_ATTRIBUTE(ns);
495 * @ns: nandsim device description object
[all …]
/openbmc/linux/security/apparmor/
H A Dpolicy_ns.c57 * aa_ns_name - Find the ns name to display for @view from @curr
71 /* at this point if a ns is visible it is in a view ns in aa_ns_name()
72 * thus the curr ns.hname is a prefix of its name. in aa_ns_name()
107 struct aa_ns *ns; in alloc_ns() local
109 ns = kzalloc(sizeof(*ns), GFP_KERNEL); in alloc_ns()
110 AA_DEBUG("%s(%p)\n", __func__, ns); in alloc_ns()
111 if (!ns) in alloc_ns()
113 if (!aa_policy_init(&ns->base, prefix, name, GFP_KERNEL)) in alloc_ns()
116 INIT_LIST_HEAD(&ns->sub_ns); in alloc_ns()
117 INIT_LIST_HEAD(&ns->rawdata_list); in alloc_ns()
[all …]
/openbmc/linux/drivers/net/netdevsim/
H A Dethtool.c14 struct netdevsim *ns = netdev_priv(dev); in nsim_get_pause_stats() local
16 if (ns->ethtool.pauseparam.report_stats_rx) in nsim_get_pause_stats()
18 if (ns->ethtool.pauseparam.report_stats_tx) in nsim_get_pause_stats()
25 struct netdevsim *ns = netdev_priv(dev); in nsim_get_pauseparam() local
28 pause->rx_pause = ns->ethtool.pauseparam.rx; in nsim_get_pauseparam()
29 pause->tx_pause = ns->ethtool.pauseparam.tx; in nsim_get_pauseparam()
35 struct netdevsim *ns = netdev_priv(dev); in nsim_set_pauseparam() local
40 ns->ethtool.pauseparam.rx = pause->rx_pause; in nsim_set_pauseparam()
41 ns->ethtool.pauseparam.tx = pause->tx_pause; in nsim_set_pauseparam()
50 struct netdevsim *ns = netdev_priv(dev); in nsim_get_coalesce() local
[all …]
H A Dnetdev.c31 struct netdevsim *ns = netdev_priv(dev); in nsim_start_xmit() local
33 if (!nsim_ipsec_tx(ns, skb)) in nsim_start_xmit()
36 u64_stats_update_begin(&ns->syncp); in nsim_start_xmit()
37 ns->tx_packets++; in nsim_start_xmit()
38 ns->tx_bytes += skb->len; in nsim_start_xmit()
39 u64_stats_update_end(&ns->syncp); in nsim_start_xmit()
53 struct netdevsim *ns = netdev_priv(dev); in nsim_change_mtu() local
55 if (ns->xdp.prog && new_mtu > NSIM_XDP_MAX_MTU) in nsim_change_mtu()
66 struct netdevsim *ns = netdev_priv(dev); in nsim_get_stats64() local
70 start = u64_stats_fetch_begin(&ns->syncp); in nsim_get_stats64()
[all …]
H A Dudp_tunnels.c15 struct netdevsim *ns = netdev_priv(dev); in nsim_udp_tunnel_set_port() local
18 ret = -ns->udp_ports.inject_error; in nsim_udp_tunnel_set_port()
19 ns->udp_ports.inject_error = 0; in nsim_udp_tunnel_set_port()
21 if (ns->udp_ports.sleep) in nsim_udp_tunnel_set_port()
22 msleep(ns->udp_ports.sleep); in nsim_udp_tunnel_set_port()
25 if (ns->udp_ports.ports[table][entry]) { in nsim_udp_tunnel_set_port()
29 ns->udp_ports.ports[table][entry] = in nsim_udp_tunnel_set_port()
44 struct netdevsim *ns = netdev_priv(dev); in nsim_udp_tunnel_unset_port() local
47 ret = -ns->udp_ports.inject_error; in nsim_udp_tunnel_unset_port()
48 ns->udp_ports.inject_error = 0; in nsim_udp_tunnel_unset_port()
[all …]
/openbmc/u-boot/drivers/spi/
H A Datcspi200_spi.c93 static int __atcspi200_spi_set_speed(struct nds_spi_slave *ns) in __atcspi200_spi_set_speed() argument
97 tm = ns->regs->timing; in __atcspi200_spi_set_speed()
100 if(ns->freq >= ns->clock) in __atcspi200_spi_set_speed()
104 if (ns->freq >= ns->clock / (2 * (div + 1))) in __atcspi200_spi_set_speed()
110 ns->regs->timing = tm; in __atcspi200_spi_set_speed()
116 static int __atcspi200_spi_claim_bus(struct nds_spi_slave *ns) in __atcspi200_spi_claim_bus() argument
119 ns->regs->ctrl |= (TXFRST|RXFRST|SPIRST); in __atcspi200_spi_claim_bus()
120 while((ns->regs->ctrl &(TXFRST|RXFRST|SPIRST))&&(ns->to--)) in __atcspi200_spi_claim_bus()
121 if(!ns->to) in __atcspi200_spi_claim_bus()
124 ns->cmd_len = 0; in __atcspi200_spi_claim_bus()
[all …]
/openbmc/linux/ipc/
H A Dnamespace.c28 static struct ucounts *inc_ipc_namespaces(struct user_namespace *ns) in inc_ipc_namespaces() argument
30 return inc_ucount(ns, current_euid(), UCOUNT_IPC_NAMESPACES); in inc_ipc_namespaces()
41 struct ipc_namespace *ns; in create_ipc_ns() local
60 ns = kzalloc(sizeof(struct ipc_namespace), GFP_KERNEL_ACCOUNT); in create_ipc_ns()
61 if (ns == NULL) in create_ipc_ns()
64 err = ns_alloc_inum(&ns->ns); in create_ipc_ns()
67 ns->ns.ops = &ipcns_operations; in create_ipc_ns()
69 refcount_set(&ns->ns.count, 1); in create_ipc_ns()
70 ns->user_ns = get_user_ns(user_ns); in create_ipc_ns()
71 ns->ucounts = ucounts; in create_ipc_ns()
[all …]
/openbmc/linux/kernel/time/
H A Dnamespace.c59 static struct ucounts *inc_time_namespaces(struct user_namespace *ns) in inc_time_namespaces() argument
61 return inc_ucount(ns, current_euid(), UCOUNT_TIME_NAMESPACES); in inc_time_namespaces()
81 struct time_namespace *ns; in clone_time_ns() local
91 ns = kmalloc(sizeof(*ns), GFP_KERNEL_ACCOUNT); in clone_time_ns()
92 if (!ns) in clone_time_ns()
95 refcount_set(&ns->ns.count, 1); in clone_time_ns()
97 ns->vvar_page = alloc_page(GFP_KERNEL_ACCOUNT | __GFP_ZERO); in clone_time_ns()
98 if (!ns->vvar_page) in clone_time_ns()
101 err = ns_alloc_inum(&ns->ns); in clone_time_ns()
105 ns->ucounts = ucounts; in clone_time_ns()
[all …]
/openbmc/linux/kernel/
H A Dutsname.c20 static struct ucounts *inc_uts_namespaces(struct user_namespace *ns) in inc_uts_namespaces() argument
22 return inc_ucount(ns, current_euid(), UCOUNT_UTS_NAMESPACES); in inc_uts_namespaces()
36 refcount_set(&uts_ns->ns.count, 1); in create_uts_ns()
41 * Clone a new ns copying an original utsname, setting refcount to 1
43 * Return ERR_PTR(-ENOMEM) on error (failure to allocate), new ns otherwise
48 struct uts_namespace *ns; in clone_uts_ns() local
58 ns = create_uts_ns(); in clone_uts_ns()
59 if (!ns) in clone_uts_ns()
62 err = ns_alloc_inum(&ns->ns); in clone_uts_ns()
66 ns->ucounts = ucounts; in clone_uts_ns()
[all …]
H A Dpid_namespace.c62 static struct ucounts *inc_pid_namespaces(struct user_namespace *ns) in inc_pid_namespaces() argument
64 return inc_ucount(ns, current_euid(), UCOUNT_PID_NAMESPACES); in inc_pid_namespaces()
75 struct pid_namespace *ns; in create_pid_namespace() local
92 ns = kmem_cache_zalloc(pid_ns_cachep, GFP_KERNEL); in create_pid_namespace()
93 if (ns == NULL) in create_pid_namespace()
96 idr_init(&ns->idr); in create_pid_namespace()
98 ns->pid_cachep = create_pid_cachep(level); in create_pid_namespace()
99 if (ns->pid_cachep == NULL) in create_pid_namespace()
102 err = ns_alloc_inum(&ns->ns); in create_pid_namespace()
105 ns->ns.ops = &pidns_operations; in create_pid_namespace()
[all …]
/openbmc/linux/drivers/nvme/host/
H A Dzns.c10 int nvme_revalidate_zones(struct nvme_ns *ns) in nvme_revalidate_zones() argument
12 struct request_queue *q = ns->queue; in nvme_revalidate_zones()
14 blk_queue_chunk_sectors(q, ns->zsze); in nvme_revalidate_zones()
15 blk_queue_max_zone_append_sectors(q, ns->ctrl->max_zone_append); in nvme_revalidate_zones()
17 return blk_revalidate_disk_zones(ns->disk, NULL); in nvme_revalidate_zones()
48 int nvme_update_zone_info(struct nvme_ns *ns, unsigned lbaf) in nvme_update_zone_info() argument
50 struct nvme_effects_log *log = ns->head->effects; in nvme_update_zone_info()
51 struct request_queue *q = ns->queue; in nvme_update_zone_info()
59 if (test_and_clear_bit(NVME_NS_FORCE_RO, &ns->flags)) in nvme_update_zone_info()
60 dev_warn(ns->ctrl->device, in nvme_update_zone_info()
[all …]
H A Dmultipath.c88 struct nvme_ns *ns = req->q->queuedata; in nvme_failover_req() local
93 nvme_mpath_clear_current_path(ns); in nvme_failover_req()
100 if (nvme_is_ana_error(status) && ns->ctrl->ana_log_buf) { in nvme_failover_req()
101 set_bit(NVME_NS_ANA_PENDING, &ns->flags); in nvme_failover_req()
102 queue_work(nvme_wq, &ns->ctrl->ana_work); in nvme_failover_req()
105 spin_lock_irqsave(&ns->head->requeue_lock, flags); in nvme_failover_req()
107 bio_set_dev(bio, ns->head->disk->part0); in nvme_failover_req()
121 blk_steal_bios(&ns->head->requeue_list, req); in nvme_failover_req()
122 spin_unlock_irqrestore(&ns->head->requeue_lock, flags); in nvme_failover_req()
126 kblockd_schedule_work(&ns->head->requeue_work); in nvme_failover_req()
[all …]
/openbmc/linux/drivers/block/drbd/
H A Ddrbd_state.c26 union drbd_state ns; member
281 union drbd_state ns, enum chg_state_flags flags,
285 static enum drbd_state_rv is_valid_transition(union drbd_state os, union drbd_state ns);
287 union drbd_state ns, enum sanitize_state_warnings *warn);
465 * @ns: new (wanted) state.
468 union drbd_state os, union drbd_state ns) in cl_wide_st_chg() argument
470 return (os.conn >= C_CONNECTED && ns.conn >= C_CONNECTED && in cl_wide_st_chg()
471 ((os.role != R_PRIMARY && ns.role == R_PRIMARY) || in cl_wide_st_chg()
472 (os.conn != C_STARTING_SYNC_T && ns.conn == C_STARTING_SYNC_T) || in cl_wide_st_chg()
473 (os.conn != C_STARTING_SYNC_S && ns.conn == C_STARTING_SYNC_S) || in cl_wide_st_chg()
[all …]
/openbmc/linux/arch/arm/boot/dts/ti/omap/
H A Domap3430-sdp.dts63 gpmc,cs-on-ns = <0>;
64 gpmc,cs-rd-off-ns = <186>;
65 gpmc,cs-wr-off-ns = <186>;
66 gpmc,adv-on-ns = <12>;
67 gpmc,adv-rd-off-ns = <48>;
68 gpmc,adv-wr-off-ns = <48>;
69 gpmc,oe-on-ns = <54>;
70 gpmc,oe-off-ns = <168>;
71 gpmc,we-on-ns = <54>;
72 gpmc,we-off-ns = <168>;
[all …]
H A Domap-gpmc-smsc911x.dtsi30 gpmc,cs-on-ns = <5>;
31 gpmc,cs-rd-off-ns = <150>;
32 gpmc,cs-wr-off-ns = <150>;
33 gpmc,adv-on-ns = <0>;
34 gpmc,adv-rd-off-ns = <15>;
35 gpmc,adv-wr-off-ns = <40>;
36 gpmc,oe-on-ns = <45>;
37 gpmc,oe-off-ns = <140>;
38 gpmc,we-on-ns = <45>;
39 gpmc,we-off-ns = <140>;
[all …]
/openbmc/linux/include/linux/
H A Dipc_namespace.h58 /* # queues in this ns, protected by mq_lock */
74 /* user_ns which owns the ipc ns */
80 struct ns_common ns; member
87 extern void shm_destroy_orphaned(struct ipc_namespace *ns);
89 static inline void shm_destroy_orphaned(struct ipc_namespace *ns) {} in shm_destroy_orphaned() argument
93 extern int mq_init_ns(struct ipc_namespace *ns);
128 static inline int mq_init_ns(struct ipc_namespace *ns) { return 0; } in mq_init_ns() argument
133 struct user_namespace *user_ns, struct ipc_namespace *ns);
135 static inline struct ipc_namespace *get_ipc_ns(struct ipc_namespace *ns) in get_ipc_ns() argument
137 if (ns) in get_ipc_ns()
[all …]
H A Duser_namespace.h76 struct ns_common ns; member
78 /* parent_could_setfcap: true if the creator if this ns had CAP_SETFCAP
79 * in its effective capability set at the child ns creation time. */
109 struct user_namespace *ns; member
119 bool setup_userns_sysctls(struct user_namespace *ns);
120 void retire_userns_sysctls(struct user_namespace *ns);
121 struct ucounts *inc_ucount(struct user_namespace *ns, kuid_t uid, enum ucount_type type);
123 struct ucounts *alloc_ucounts(struct user_namespace *ns, kuid_t uid);
139 static inline long get_userns_rlimit_max(struct user_namespace *ns, enum rlimit_type type) in get_userns_rlimit_max() argument
141 return READ_ONCE(ns->rlimit_max[type]); in get_userns_rlimit_max()
[all …]
H A Dpid_namespace.h40 struct ns_common ns; member
51 static inline struct pid_namespace *get_pid_ns(struct pid_namespace *ns) in get_pid_ns() argument
53 if (ns != &init_pid_ns) in get_pid_ns()
54 refcount_inc(&ns->ns.count); in get_pid_ns()
55 return ns; in get_pid_ns()
59 static inline int pidns_memfd_noexec_scope(struct pid_namespace *ns) in pidns_memfd_noexec_scope() argument
63 for (; ns; ns = ns->parent) in pidns_memfd_noexec_scope()
64 scope = max(scope, READ_ONCE(ns->memfd_noexec_scope)); in pidns_memfd_noexec_scope()
69 static inline int pidns_memfd_noexec_scope(struct pid_namespace *ns) in pidns_memfd_noexec_scope() argument
76 struct user_namespace *user_ns, struct pid_namespace *ns);
[all …]
/openbmc/linux/kernel/cgroup/
H A Dnamespace.c12 static struct ucounts *inc_cgroup_namespaces(struct user_namespace *ns) in inc_cgroup_namespaces() argument
14 return inc_ucount(ns, current_euid(), UCOUNT_CGROUP_NAMESPACES); in inc_cgroup_namespaces()
30 ret = ns_alloc_inum(&new_ns->ns); in alloc_cgroup_ns()
35 refcount_set(&new_ns->ns.count, 1); in alloc_cgroup_ns()
36 new_ns->ns.ops = &cgroupns_operations; in alloc_cgroup_ns()
40 void free_cgroup_ns(struct cgroup_namespace *ns) in free_cgroup_ns() argument
42 put_css_set(ns->root_cset); in free_cgroup_ns()
43 dec_cgroup_namespaces(ns->ucounts); in free_cgroup_ns()
44 put_user_ns(ns->user_ns); in free_cgroup_ns()
45 ns_free_inum(&ns->ns); in free_cgroup_ns()
[all …]
/openbmc/linux/fs/
H A Dnsfs.c40 struct ns_common *ns = inode->i_private; in ns_prune_dentry() local
41 atomic_long_set(&ns->stashed, 0); in ns_prune_dentry()
54 struct ns_common *ns = inode->i_private; in nsfs_evict() local
56 ns->ops->put(ns); in nsfs_evict()
59 static int __ns_get_path(struct path *path, struct ns_common *ns) in __ns_get_path() argument
67 d = atomic_long_read(&ns->stashed); in __ns_get_path()
74 ns->ops->put(ns); in __ns_get_path()
83 ns->ops->put(ns); in __ns_get_path()
86 inode->i_ino = ns->inum; in __ns_get_path()
91 inode->i_private = ns; in __ns_get_path()
[all …]
/openbmc/u-boot/arch/arm/dts/
H A Domap-gpmc-smsc911x.dtsi30 gpmc,cs-on-ns = <5>;
31 gpmc,cs-rd-off-ns = <150>;
32 gpmc,cs-wr-off-ns = <150>;
33 gpmc,adv-on-ns = <0>;
34 gpmc,adv-rd-off-ns = <15>;
35 gpmc,adv-wr-off-ns = <40>;
36 gpmc,oe-on-ns = <45>;
37 gpmc,oe-off-ns = <140>;
38 gpmc,we-on-ns = <45>;
39 gpmc,we-off-ns = <140>;
[all …]
/openbmc/linux/tools/testing/selftests/drivers/net/mlxsw/
H A Dfib.sh96 local ns="testns1"
100 ip -n $ns link add name dummy1 type dummy
101 ip -n $ns link set dev dummy1 up
103 ip -n $ns route add table local 192.0.2.1/32 dev dummy1
104 fib4_trap_check $ns "table local 192.0.2.1/32 dev dummy1" false
107 ip -n $ns route add table main 192.0.2.1/32 dev dummy1
108 fib4_trap_check $ns "table main 192.0.2.1/32 dev dummy1" true
111 fib4_trap_check $ns "table local 192.0.2.1/32 dev dummy1" false
115 ip -n $ns route add table main 192.0.2.2/32 dev dummy1
116 fib4_trap_check $ns "table main 192.0.2.2/32 dev dummy1" false
[all …]

12345678910>>...101