hp                402 arch/mips/sgi-ip22/ip28-berr.c 		struct hpc3_stat *hp = (struct hpc3_stat *)&hpc3 + i;
hp                404 arch/mips/sgi-ip22/ip28-berr.c 		    (cpu_err_addr == hp->ndptr || cpu_err_addr == hp->cbp))
hp                407 arch/mips/sgi-ip22/ip28-berr.c 		    (gio_err_addr == hp->ndptr || gio_err_addr == hp->cbp))
hp                411 arch/mips/sgi-ip22/ip28-berr.c 		struct hpc3_stat *hp = (struct hpc3_stat *)&hpc3 + i;
hp                414 arch/mips/sgi-ip22/ip28-berr.c 		       CPHYSADDR(hp->addr), hp->ctrl, hp->ndptr, hp->cbp);
hp                 87 arch/powerpc/include/asm/hvsi.h extern int hvsilib_open(struct hvsi_priv *pv, struct hvc_struct *hp);
hp                 88 arch/powerpc/include/asm/hvsi.h extern void hvsilib_close(struct hvsi_priv *pv, struct hvc_struct *hp);
hp                995 arch/powerpc/kvm/book3s_64_mmu_hv.c 	unsigned long *hp;
hp               1010 arch/powerpc/kvm/book3s_64_mmu_hv.c 			hp = (unsigned long *)(kvm->arch.hpt.virt + (i << 4));
hp               1012 arch/powerpc/kvm/book3s_64_mmu_hv.c 			if (be64_to_cpu(hp[1]) & HPTE_R_R)
hp                571 arch/powerpc/kvm/book3s_hv_rm_mmu.c 	__be64 *hp, *hptes[4];
hp                603 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			hp = (__be64 *) (kvm->arch.hpt.virt + (pte_index << 4));
hp                605 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			if (!try_lock_hpte(hp, HPTE_V_HVLOCK)) {
hp                608 arch/powerpc/kvm/book3s_hv_rm_mmu.c 				while (!try_lock_hpte(hp, HPTE_V_HVLOCK))
hp                612 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			hp0 = be64_to_cpu(hp[0]);
hp                613 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			hp1 = be64_to_cpu(hp[1]);
hp                634 arch/powerpc/kvm/book3s_hv_rm_mmu.c 				hp[0] &= ~cpu_to_be64(HPTE_V_HVLOCK);
hp                647 arch/powerpc/kvm/book3s_hv_rm_mmu.c 				hp[0] = 0;
hp                654 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			hp[0] &= ~cpu_to_be64(HPTE_V_VALID);
hp                657 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			hptes[n] = hp;
hp                672 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			hp = hptes[k];
hp                675 arch/powerpc/kvm/book3s_hv_rm_mmu.c 				be64_to_cpu(hp[0]), be64_to_cpu(hp[1]));
hp                678 arch/powerpc/kvm/book3s_hv_rm_mmu.c 			__unlock_hpte(hp, 0);
hp                662 arch/powerpc/lib/sstep.c 	const unsigned short *hp;
hp                721 arch/powerpc/lib/sstep.c 		hp = mem;
hp                724 arch/powerpc/lib/sstep.c 			reg->h[i] = !rev ? *hp++ : byterev_2(*hp++);
hp                747 arch/powerpc/lib/sstep.c 	unsigned short *hp;
hp                797 arch/powerpc/lib/sstep.c 		hp = mem;
hp                800 arch/powerpc/lib/sstep.c 			*hp++ = !rev ? reg->h[i] : byterev_2(reg->h[i]);
hp                 41 arch/sparc/include/asm/mdesc.h const char *mdesc_node_name(struct mdesc_handle *hp, u64 node);
hp                 62 arch/sparc/include/asm/mdesc.h u64 mdesc_arc_target(struct mdesc_handle *hp, u64 arc);
hp                 88 arch/sparc/include/asm/mdesc.h u64 mdesc_get_node(struct mdesc_handle *hp, const char *node_name,
hp                 90 arch/sparc/include/asm/mdesc.h int mdesc_get_node_info(struct mdesc_handle *hp, u64 node,
hp                513 arch/sparc/include/asm/vio.h u64 vio_vdev_node(struct mdesc_handle *hp, struct vio_dev *vdev);
hp                 40 arch/sparc/kernel/adi_64.c 	struct mdesc_handle *hp = mdesc_grab();
hp                 45 arch/sparc/kernel/adi_64.c 	if (!hp)
hp                 48 arch/sparc/kernel/adi_64.c 	pn = mdesc_node_by_name(hp, MDESC_NODE_NULL, "cpu");
hp                 52 arch/sparc/kernel/adi_64.c 	prop = mdesc_get_property(hp, pn, "hwcap-list", &len);
hp                 81 arch/sparc/kernel/adi_64.c 	pn = mdesc_node_by_name(hp, MDESC_NODE_NULL, "platform");
hp                 85 arch/sparc/kernel/adi_64.c 	val = (u64 *) mdesc_get_property(hp, pn, "adp-blksz", &len);
hp                 90 arch/sparc/kernel/adi_64.c 	val = (u64 *) mdesc_get_property(hp, pn, "adp-nbits", &len);
hp                 95 arch/sparc/kernel/adi_64.c 	val = (u64 *) mdesc_get_property(hp, pn, "ue-on-adp", &len);
hp                113 arch/sparc/kernel/adi_64.c 	mdesc_release(hp);
hp                120 arch/sparc/kernel/adi_64.c 	if (hp)
hp                121 arch/sparc/kernel/adi_64.c 		mdesc_release(hp);
hp               1166 arch/sparc/kernel/ds.c 	struct mdesc_handle *hp;
hp               1180 arch/sparc/kernel/ds.c 	hp = mdesc_grab();
hp               1181 arch/sparc/kernel/ds.c 	val = mdesc_get_property(hp, vdev->mp, "id", NULL);
hp               1184 arch/sparc/kernel/ds.c 	mdesc_release(hp);
hp               2389 arch/sparc/kernel/ldc.c 	struct mdesc_handle *hp;
hp               2394 arch/sparc/kernel/ldc.c 	hp = mdesc_grab();
hp               2395 arch/sparc/kernel/ldc.c 	if (!hp)
hp               2398 arch/sparc/kernel/ldc.c 	mp = mdesc_node_by_name(hp, MDESC_NODE_NULL, "platform");
hp               2403 arch/sparc/kernel/ldc.c 	v = mdesc_get_property(hp, mp, "domaining-enabled", NULL);
hp               2424 arch/sparc/kernel/ldc.c 	mdesc_release(hp);
hp                148 arch/sparc/kernel/mdesc.c static void mdesc_handle_init(struct mdesc_handle *hp,
hp                152 arch/sparc/kernel/mdesc.c 	BUG_ON(((unsigned long)&hp->mdesc) & (16UL - 1));
hp                154 arch/sparc/kernel/mdesc.c 	memset(hp, 0, handle_size);
hp                155 arch/sparc/kernel/mdesc.c 	INIT_LIST_HEAD(&hp->list);
hp                156 arch/sparc/kernel/mdesc.c 	hp->self_base = base;
hp                157 arch/sparc/kernel/mdesc.c 	refcount_set(&hp->refcnt, 1);
hp                158 arch/sparc/kernel/mdesc.c 	hp->handle_size = handle_size;
hp                164 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp;
hp                174 arch/sparc/kernel/mdesc.c 	hp = NULL;
hp                176 arch/sparc/kernel/mdesc.c 		hp = __va(paddr);
hp                177 arch/sparc/kernel/mdesc.c 		mdesc_handle_init(hp, handle_size, hp);
hp                179 arch/sparc/kernel/mdesc.c 	return hp;
hp                182 arch/sparc/kernel/mdesc.c static void __init mdesc_memblock_free(struct mdesc_handle *hp)
hp                187 arch/sparc/kernel/mdesc.c 	BUG_ON(refcount_read(&hp->refcnt) != 0);
hp                188 arch/sparc/kernel/mdesc.c 	BUG_ON(!list_empty(&hp->list));
hp                190 arch/sparc/kernel/mdesc.c 	alloc_size = PAGE_ALIGN(hp->handle_size);
hp                191 arch/sparc/kernel/mdesc.c 	start = __pa(hp);
hp                203 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp;
hp                216 arch/sparc/kernel/mdesc.c 	hp = (struct mdesc_handle *) addr;
hp                218 arch/sparc/kernel/mdesc.c 	mdesc_handle_init(hp, handle_size, base);
hp                220 arch/sparc/kernel/mdesc.c 	return hp;
hp                223 arch/sparc/kernel/mdesc.c static void mdesc_kfree(struct mdesc_handle *hp)
hp                225 arch/sparc/kernel/mdesc.c 	BUG_ON(refcount_read(&hp->refcnt) != 0);
hp                226 arch/sparc/kernel/mdesc.c 	BUG_ON(!list_empty(&hp->list));
hp                228 arch/sparc/kernel/mdesc.c 	kfree(hp->self_base);
hp                239 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp = mops->alloc(mdesc_size);
hp                241 arch/sparc/kernel/mdesc.c 	if (hp)
hp                242 arch/sparc/kernel/mdesc.c 		hp->mops = mops;
hp                244 arch/sparc/kernel/mdesc.c 	return hp;
hp                247 arch/sparc/kernel/mdesc.c static void mdesc_free(struct mdesc_handle *hp)
hp                249 arch/sparc/kernel/mdesc.c 	hp->mops->free(hp);
hp                258 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp;
hp                262 arch/sparc/kernel/mdesc.c 	hp = cur_mdesc;
hp                263 arch/sparc/kernel/mdesc.c 	if (hp)
hp                264 arch/sparc/kernel/mdesc.c 		refcount_inc(&hp->refcnt);
hp                267 arch/sparc/kernel/mdesc.c 	return hp;
hp                271 arch/sparc/kernel/mdesc.c void mdesc_release(struct mdesc_handle *hp)
hp                276 arch/sparc/kernel/mdesc.c 	if (refcount_dec_and_test(&hp->refcnt)) {
hp                277 arch/sparc/kernel/mdesc.c 		list_del_init(&hp->list);
hp                278 arch/sparc/kernel/mdesc.c 		hp->mops->free(hp);
hp                318 arch/sparc/kernel/mdesc.c static const u64 *parent_cfg_handle(struct mdesc_handle *hp, u64 node)
hp                324 arch/sparc/kernel/mdesc.c 	mdesc_for_each_arc(a, hp, node, MDESC_ARC_TYPE_BACK) {
hp                327 arch/sparc/kernel/mdesc.c 		target = mdesc_arc_target(hp, a);
hp                328 arch/sparc/kernel/mdesc.c 		id = mdesc_get_property(hp, target,
hp                503 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp, *orig_hp;
hp                510 arch/sparc/kernel/mdesc.c 	hp = mdesc_alloc(len, &kmalloc_mdesc_memops);
hp                511 arch/sparc/kernel/mdesc.c 	if (!hp) {
hp                516 arch/sparc/kernel/mdesc.c 	status = sun4v_mach_desc(__pa(&hp->mdesc), len, &real_len);
hp                520 arch/sparc/kernel/mdesc.c 		refcount_dec(&hp->refcnt);
hp                521 arch/sparc/kernel/mdesc.c 		mdesc_free(hp);
hp                527 arch/sparc/kernel/mdesc.c 	cur_mdesc = hp;
hp                530 arch/sparc/kernel/mdesc.c 	mdesc_notify_clients(orig_hp, hp);
hp                543 arch/sparc/kernel/mdesc.c u64 mdesc_get_node(struct mdesc_handle *hp, const char *node_name,
hp                553 arch/sparc/kernel/mdesc.c 	if (hp == NULL || node_name == NULL || node_info == NULL)
hp                566 arch/sparc/kernel/mdesc.c 	mdesc_for_each_node_by_name(hp, hp_node, node_name) {
hp                567 arch/sparc/kernel/mdesc.c 		rv = get_info_func(hp, hp_node, &hp_node_info);
hp                583 arch/sparc/kernel/mdesc.c int mdesc_get_node_info(struct mdesc_handle *hp, u64 node,
hp                589 arch/sparc/kernel/mdesc.c 	if (hp == NULL || node == MDESC_NODE_NULL ||
hp                602 arch/sparc/kernel/mdesc.c 	rv = get_info_func(hp, node, node_info);
hp                628 arch/sparc/kernel/mdesc.c u64 mdesc_node_by_name(struct mdesc_handle *hp,
hp                631 arch/sparc/kernel/mdesc.c 	struct mdesc_elem *ep = node_block(&hp->mdesc);
hp                632 arch/sparc/kernel/mdesc.c 	const char *names = name_block(&hp->mdesc);
hp                633 arch/sparc/kernel/mdesc.c 	u64 last_node = hp->mdesc.node_sz / 16;
hp                657 arch/sparc/kernel/mdesc.c const void *mdesc_get_property(struct mdesc_handle *hp, u64 node,
hp                660 arch/sparc/kernel/mdesc.c 	const char *names = name_block(&hp->mdesc);
hp                661 arch/sparc/kernel/mdesc.c 	u64 last_node = hp->mdesc.node_sz / 16;
hp                662 arch/sparc/kernel/mdesc.c 	void *data = data_block(&hp->mdesc);
hp                668 arch/sparc/kernel/mdesc.c 	ep = node_block(&hp->mdesc) + node;
hp                703 arch/sparc/kernel/mdesc.c u64 mdesc_next_arc(struct mdesc_handle *hp, u64 from, const char *arc_type)
hp                705 arch/sparc/kernel/mdesc.c 	struct mdesc_elem *ep, *base = node_block(&hp->mdesc);
hp                706 arch/sparc/kernel/mdesc.c 	const char *names = name_block(&hp->mdesc);
hp                707 arch/sparc/kernel/mdesc.c 	u64 last_node = hp->mdesc.node_sz / 16;
hp                729 arch/sparc/kernel/mdesc.c u64 mdesc_arc_target(struct mdesc_handle *hp, u64 arc)
hp                731 arch/sparc/kernel/mdesc.c 	struct mdesc_elem *ep, *base = node_block(&hp->mdesc);
hp                739 arch/sparc/kernel/mdesc.c const char *mdesc_node_name(struct mdesc_handle *hp, u64 node)
hp                741 arch/sparc/kernel/mdesc.c 	struct mdesc_elem *ep, *base = node_block(&hp->mdesc);
hp                742 arch/sparc/kernel/mdesc.c 	const char *names = name_block(&hp->mdesc);
hp                743 arch/sparc/kernel/mdesc.c 	u64 last_node = hp->mdesc.node_sz / 16;
hp                760 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp = mdesc_grab();
hp                761 arch/sparc/kernel/mdesc.c 	u64 pn = mdesc_node_by_name(hp, MDESC_NODE_NULL, "platform");
hp                770 arch/sparc/kernel/mdesc.c 	s = mdesc_get_property(hp, pn, "banner-name", NULL);
hp                772 arch/sparc/kernel/mdesc.c 	s = mdesc_get_property(hp, pn, "name", NULL);
hp                775 arch/sparc/kernel/mdesc.c 	v = mdesc_get_property(hp, pn, "hostid", NULL);
hp                778 arch/sparc/kernel/mdesc.c 	v = mdesc_get_property(hp, pn, "serial#", NULL);
hp                781 arch/sparc/kernel/mdesc.c 	v = mdesc_get_property(hp, pn, "stick-frequency", NULL);
hp                783 arch/sparc/kernel/mdesc.c 	v = mdesc_get_property(hp, pn, "mac-address", NULL);
hp                786 arch/sparc/kernel/mdesc.c 	v = mdesc_get_property(hp, pn, "watchdog-resolution", NULL);
hp                789 arch/sparc/kernel/mdesc.c 	v = mdesc_get_property(hp, pn, "watchdog-max-timeout", NULL);
hp                792 arch/sparc/kernel/mdesc.c 	v = mdesc_get_property(hp, pn, "max-cpus", NULL);
hp                814 arch/sparc/kernel/mdesc.c 	mdesc_release(hp);
hp                817 arch/sparc/kernel/mdesc.c static void fill_in_one_cache(cpuinfo_sparc *c, struct mdesc_handle *hp, u64 mp)
hp                819 arch/sparc/kernel/mdesc.c 	const u64 *level = mdesc_get_property(hp, mp, "level", NULL);
hp                820 arch/sparc/kernel/mdesc.c 	const u64 *size = mdesc_get_property(hp, mp, "size", NULL);
hp                821 arch/sparc/kernel/mdesc.c 	const u64 *line_size = mdesc_get_property(hp, mp, "line-size", NULL);
hp                825 arch/sparc/kernel/mdesc.c 	type = mdesc_get_property(hp, mp, "type", &type_len);
hp                850 arch/sparc/kernel/mdesc.c 		mdesc_for_each_arc(a, hp, mp, MDESC_ARC_TYPE_FWD) {
hp                851 arch/sparc/kernel/mdesc.c 			u64 target = mdesc_arc_target(hp, a);
hp                852 arch/sparc/kernel/mdesc.c 			const char *name = mdesc_node_name(hp, target);
hp                855 arch/sparc/kernel/mdesc.c 				fill_in_one_cache(c, hp, target);
hp                860 arch/sparc/kernel/mdesc.c static void find_back_node_value(struct mdesc_handle *hp, u64 node,
hp                871 arch/sparc/kernel/mdesc.c 	mdesc_for_each_arc(arc, hp, node, MDESC_ARC_TYPE_BACK) {
hp                872 arch/sparc/kernel/mdesc.c 		u64 n = mdesc_arc_target(hp, arc);
hp                873 arch/sparc/kernel/mdesc.c 		const char *name = mdesc_node_name(hp, n);
hp                876 arch/sparc/kernel/mdesc.c 			(*func)(hp, n, val);
hp                878 arch/sparc/kernel/mdesc.c 		find_back_node_value(hp, n, srch_val, func, val, depth-1);
hp                882 arch/sparc/kernel/mdesc.c static void __mark_core_id(struct mdesc_handle *hp, u64 node,
hp                885 arch/sparc/kernel/mdesc.c 	const u64 *id = mdesc_get_property(hp, node, "id", NULL);
hp                891 arch/sparc/kernel/mdesc.c static void __mark_max_cache_id(struct mdesc_handle *hp, u64 node,
hp                894 arch/sparc/kernel/mdesc.c 	const u64 *id = mdesc_get_property(hp, node, "id", NULL);
hp                907 arch/sparc/kernel/mdesc.c static void mark_core_ids(struct mdesc_handle *hp, u64 mp,
hp                910 arch/sparc/kernel/mdesc.c 	find_back_node_value(hp, mp, "cpu", __mark_core_id, core_id, 10);
hp                913 arch/sparc/kernel/mdesc.c static void mark_max_cache_ids(struct mdesc_handle *hp, u64 mp,
hp                916 arch/sparc/kernel/mdesc.c 	find_back_node_value(hp, mp, "cpu", __mark_max_cache_id,
hp                920 arch/sparc/kernel/mdesc.c static void set_core_ids(struct mdesc_handle *hp)
hp                930 arch/sparc/kernel/mdesc.c 	mdesc_for_each_node_by_name(hp, mp, "cache") {
hp                935 arch/sparc/kernel/mdesc.c 		level = mdesc_get_property(hp, mp, "level", NULL);
hp                939 arch/sparc/kernel/mdesc.c 		type = mdesc_get_property(hp, mp, "type", &len);
hp                943 arch/sparc/kernel/mdesc.c 		mark_core_ids(hp, mp, idx);
hp                948 arch/sparc/kernel/mdesc.c static int set_max_cache_ids_by_cache(struct mdesc_handle *hp, int level)
hp                958 arch/sparc/kernel/mdesc.c 	mdesc_for_each_node_by_name(hp, mp, "cache") {
hp                961 arch/sparc/kernel/mdesc.c 		cur_lvl = mdesc_get_property(hp, mp, "level", NULL);
hp                964 arch/sparc/kernel/mdesc.c 		mark_max_cache_ids(hp, mp, idx);
hp                971 arch/sparc/kernel/mdesc.c static void set_sock_ids_by_socket(struct mdesc_handle *hp, u64 mp)
hp                975 arch/sparc/kernel/mdesc.c 	mdesc_for_each_node_by_name(hp, mp, "socket") {
hp                978 arch/sparc/kernel/mdesc.c 		mdesc_for_each_arc(a, hp, mp, MDESC_ARC_TYPE_FWD) {
hp                979 arch/sparc/kernel/mdesc.c 			u64 t = mdesc_arc_target(hp, a);
hp                983 arch/sparc/kernel/mdesc.c 			name = mdesc_node_name(hp, t);
hp                987 arch/sparc/kernel/mdesc.c 			id = mdesc_get_property(hp, t, "id", NULL);
hp                995 arch/sparc/kernel/mdesc.c static void set_sock_ids(struct mdesc_handle *hp)
hp               1003 arch/sparc/kernel/mdesc.c 	if (!set_max_cache_ids_by_cache(hp, 3))
hp               1004 arch/sparc/kernel/mdesc.c 		set_max_cache_ids_by_cache(hp, 2);
hp               1007 arch/sparc/kernel/mdesc.c 	mp = mdesc_node_by_name(hp, MDESC_NODE_NULL, "sockets");
hp               1009 arch/sparc/kernel/mdesc.c 		set_sock_ids_by_socket(hp, mp);
hp               1012 arch/sparc/kernel/mdesc.c static void mark_proc_ids(struct mdesc_handle *hp, u64 mp, int proc_id)
hp               1016 arch/sparc/kernel/mdesc.c 	mdesc_for_each_arc(a, hp, mp, MDESC_ARC_TYPE_BACK) {
hp               1017 arch/sparc/kernel/mdesc.c 		u64 t = mdesc_arc_target(hp, a);
hp               1021 arch/sparc/kernel/mdesc.c 		name = mdesc_node_name(hp, t);
hp               1025 arch/sparc/kernel/mdesc.c 		id = mdesc_get_property(hp, t, "id", NULL);
hp               1031 arch/sparc/kernel/mdesc.c static void __set_proc_ids(struct mdesc_handle *hp, const char *exec_unit_name)
hp               1037 arch/sparc/kernel/mdesc.c 	mdesc_for_each_node_by_name(hp, mp, exec_unit_name) {
hp               1041 arch/sparc/kernel/mdesc.c 		type = mdesc_get_property(hp, mp, "type", &len);
hp               1046 arch/sparc/kernel/mdesc.c 		mark_proc_ids(hp, mp, idx);
hp               1051 arch/sparc/kernel/mdesc.c static void set_proc_ids(struct mdesc_handle *hp)
hp               1053 arch/sparc/kernel/mdesc.c 	__set_proc_ids(hp, "exec_unit");
hp               1054 arch/sparc/kernel/mdesc.c 	__set_proc_ids(hp, "exec-unit");
hp               1079 arch/sparc/kernel/mdesc.c static void get_mondo_data(struct mdesc_handle *hp, u64 mp,
hp               1085 arch/sparc/kernel/mdesc.c 	val = mdesc_get_property(hp, mp, "q-cpu-mondo-#bits", NULL);
hp               1088 arch/sparc/kernel/mdesc.c 	val = mdesc_get_property(hp, mp, "q-dev-mondo-#bits", NULL);
hp               1091 arch/sparc/kernel/mdesc.c 	val = mdesc_get_property(hp, mp, "q-resumable-#bits", NULL);
hp               1094 arch/sparc/kernel/mdesc.c 	val = mdesc_get_property(hp, mp, "q-nonresumable-#bits", NULL);
hp               1108 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp = mdesc_grab();
hp               1112 arch/sparc/kernel/mdesc.c 	mdesc_for_each_node_by_name(hp, mp, "cpu") {
hp               1113 arch/sparc/kernel/mdesc.c 		const u64 *id = mdesc_get_property(hp, mp, "id", NULL);
hp               1127 arch/sparc/kernel/mdesc.c 		ret = func(hp, mp, cpuid, arg);
hp               1132 arch/sparc/kernel/mdesc.c 	mdesc_release(hp);
hp               1136 arch/sparc/kernel/mdesc.c static void *record_one_cpu(struct mdesc_handle *hp, u64 mp, int cpuid,
hp               1155 arch/sparc/kernel/mdesc.c static void * __init check_one_pgsz(struct mdesc_handle *hp, u64 mp, int cpuid, void *arg)
hp               1157 arch/sparc/kernel/mdesc.c 	const u64 *pgsz_prop = mdesc_get_property(hp, mp, "mmu-page-size-list", NULL);
hp               1179 arch/sparc/kernel/mdesc.c static void *fill_in_one_cpu(struct mdesc_handle *hp, u64 mp, int cpuid,
hp               1182 arch/sparc/kernel/mdesc.c 	const u64 *cfreq = mdesc_get_property(hp, mp, "clock-frequency", NULL);
hp               1201 arch/sparc/kernel/mdesc.c 	get_mondo_data(hp, mp, tb);
hp               1203 arch/sparc/kernel/mdesc.c 	mdesc_for_each_arc(a, hp, mp, MDESC_ARC_TYPE_FWD) {
hp               1204 arch/sparc/kernel/mdesc.c 		u64 j, t = mdesc_arc_target(hp, a);
hp               1207 arch/sparc/kernel/mdesc.c 		t_name = mdesc_node_name(hp, t);
hp               1209 arch/sparc/kernel/mdesc.c 			fill_in_one_cache(c, hp, t);
hp               1213 arch/sparc/kernel/mdesc.c 		mdesc_for_each_arc(j, hp, t, MDESC_ARC_TYPE_FWD) {
hp               1214 arch/sparc/kernel/mdesc.c 			u64 n = mdesc_arc_target(hp, j);
hp               1217 arch/sparc/kernel/mdesc.c 			n_name = mdesc_node_name(hp, n);
hp               1219 arch/sparc/kernel/mdesc.c 				fill_in_one_cache(c, hp, n);
hp               1231 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp;
hp               1235 arch/sparc/kernel/mdesc.c 	hp = mdesc_grab();
hp               1237 arch/sparc/kernel/mdesc.c 	set_core_ids(hp);
hp               1238 arch/sparc/kernel/mdesc.c 	set_proc_ids(hp);
hp               1239 arch/sparc/kernel/mdesc.c 	set_sock_ids(hp);
hp               1241 arch/sparc/kernel/mdesc.c 	mdesc_release(hp);
hp               1253 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp = mdesc_grab();
hp               1255 arch/sparc/kernel/mdesc.c 	if (!hp)
hp               1258 arch/sparc/kernel/mdesc.c 	file->private_data = hp;
hp               1266 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp = file->private_data;
hp               1270 arch/sparc/kernel/mdesc.c 	if (*offp >= hp->handle_size)
hp               1273 arch/sparc/kernel/mdesc.c 	bytes_left = hp->handle_size - *offp;
hp               1277 arch/sparc/kernel/mdesc.c 	mdesc = (unsigned char *)&hp->mdesc;
hp               1289 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp = file->private_data;
hp               1291 arch/sparc/kernel/mdesc.c 	return no_seek_end_llseek_size(file, offset, whence, hp->handle_size);
hp               1326 arch/sparc/kernel/mdesc.c 	struct mdesc_handle *hp;
hp               1333 arch/sparc/kernel/mdesc.c 	hp = mdesc_alloc(len, &memblock_mdesc_ops);
hp               1334 arch/sparc/kernel/mdesc.c 	if (hp == NULL) {
hp               1339 arch/sparc/kernel/mdesc.c 	status = sun4v_mach_desc(__pa(&hp->mdesc), len, &real_len);
hp               1344 arch/sparc/kernel/mdesc.c 		mdesc_free(hp);
hp               1348 arch/sparc/kernel/mdesc.c 	cur_mdesc = hp;
hp                487 arch/sparc/kernel/setup_64.c 	struct mdesc_handle *hp;
hp                493 arch/sparc/kernel/setup_64.c 	hp = mdesc_grab();
hp                494 arch/sparc/kernel/setup_64.c 	if (!hp)
hp                497 arch/sparc/kernel/setup_64.c 	pn = mdesc_node_by_name(hp, MDESC_NODE_NULL, "cpu");
hp                501 arch/sparc/kernel/setup_64.c 	prop = mdesc_get_property(hp, pn, "hwcap-list", &len);
hp                527 arch/sparc/kernel/setup_64.c 	mdesc_release(hp);
hp                207 arch/sparc/kernel/vio.c static const u64 *vio_cfg_handle(struct mdesc_handle *hp, u64 node)
hp                212 arch/sparc/kernel/vio.c 	mdesc_for_each_arc(a, hp, node, MDESC_ARC_TYPE_BACK) {
hp                215 arch/sparc/kernel/vio.c 		target = mdesc_arc_target(hp, a);
hp                216 arch/sparc/kernel/vio.c 		cfg_handle = mdesc_get_property(hp, target,
hp                238 arch/sparc/kernel/vio.c u64 vio_vdev_node(struct mdesc_handle *hp, struct vio_dev *vdev)
hp                245 arch/sparc/kernel/vio.c 	node = mdesc_get_node(hp, (const char *)vdev->node_name,
hp                252 arch/sparc/kernel/vio.c static void vio_fill_channel_info(struct mdesc_handle *hp, u64 mp,
hp                260 arch/sparc/kernel/vio.c 	mdesc_for_each_arc(a, hp, mp, MDESC_ARC_TYPE_FWD) {
hp                265 arch/sparc/kernel/vio.c 		target = mdesc_arc_target(hp, a);
hp                267 arch/sparc/kernel/vio.c 		irq = mdesc_get_property(hp, target, "tx-ino", NULL);
hp                271 arch/sparc/kernel/vio.c 		irq = mdesc_get_property(hp, target, "rx-ino", NULL);
hp                275 arch/sparc/kernel/vio.c 		chan_id = mdesc_get_property(hp, target, "id", NULL);
hp                292 arch/sparc/kernel/vio.c static struct vio_dev *vio_create_one(struct mdesc_handle *hp, u64 mp,
hp                302 arch/sparc/kernel/vio.c 	type = mdesc_get_property(hp, mp, "device-type", &tlen);
hp                304 arch/sparc/kernel/vio.c 		type = mdesc_get_property(hp, mp, "name", &tlen);
hp                306 arch/sparc/kernel/vio.c 			type = mdesc_node_name(hp, mp);
hp                316 arch/sparc/kernel/vio.c 	id = mdesc_get_property(hp, mp, "id", NULL);
hp                318 arch/sparc/kernel/vio.c 	cfg_handle = vio_cfg_handle(hp, mp);
hp                320 arch/sparc/kernel/vio.c 	compat = mdesc_get_property(hp, mp, "device-type", &clen);
hp                347 arch/sparc/kernel/vio.c 	vio_fill_channel_info(hp, mp, vdev);
hp                386 arch/sparc/kernel/vio.c 		err = mdesc_get_node_info(hp, mp, node_name,
hp                413 arch/sparc/kernel/vio.c static void vio_add(struct mdesc_handle *hp, u64 node,
hp                416 arch/sparc/kernel/vio.c 	(void) vio_create_one(hp, node, node_name, &root_vdev->dev);
hp                420 arch/sparc/kernel/vio.c 	struct mdesc_handle *hp;
hp                432 arch/sparc/kernel/vio.c 	node = vio_vdev_node(node_data->hp, vdev);
hp                440 arch/sparc/kernel/vio.c static void vio_remove(struct mdesc_handle *hp, u64 node, const char *node_name)
hp                445 arch/sparc/kernel/vio.c 	node_data.hp = hp;
hp                471 arch/sparc/kernel/vio.c static void vio_add_ds(struct mdesc_handle *hp, u64 node,
hp                478 arch/sparc/kernel/vio.c 	mdesc_for_each_arc(a, hp, node, MDESC_ARC_TYPE_BACK) {
hp                479 arch/sparc/kernel/vio.c 		u64 target = mdesc_arc_target(hp, a);
hp                480 arch/sparc/kernel/vio.c 		const char *name = mdesc_node_name(hp, target);
hp                489 arch/sparc/kernel/vio.c 		(void) vio_create_one(hp, node, node_name, &root_vdev->dev);
hp                504 arch/sparc/kernel/vio.c 	struct mdesc_handle *hp;
hp                517 arch/sparc/kernel/vio.c 	hp = mdesc_grab();
hp                518 arch/sparc/kernel/vio.c 	if (!hp)
hp                521 arch/sparc/kernel/vio.c 	root = mdesc_node_by_name(hp, MDESC_NODE_NULL, channel_devices_node);
hp                524 arch/sparc/kernel/vio.c 		mdesc_release(hp);
hp                535 arch/sparc/kernel/vio.c 	compat = mdesc_get_property(hp, root, "compatible", &len);
hp                547 arch/sparc/kernel/vio.c 	cfg_handle = mdesc_get_property(hp, root, cfg_handle_prop, NULL);
hp                556 arch/sparc/kernel/vio.c 	root_vdev = vio_create_one(hp, root, NULL, NULL);
hp                566 arch/sparc/kernel/vio.c 	mdesc_release(hp);
hp                571 arch/sparc/kernel/vio.c 	mdesc_release(hp);
hp                292 arch/sparc/mm/tsb.c 		struct hv_tsb_descr *hp = &mm->context.tsb_descr[tsb_idx];
hp                296 arch/sparc/mm/tsb.c 			hp->pgsz_idx = HV_PGSZ_IDX_BASE;
hp                300 arch/sparc/mm/tsb.c 			hp->pgsz_idx = HV_PGSZ_IDX_HUGE;
hp                306 arch/sparc/mm/tsb.c 		hp->assoc = 1;
hp                307 arch/sparc/mm/tsb.c 		hp->num_ttes = tsb_bytes / 16;
hp                308 arch/sparc/mm/tsb.c 		hp->ctx_idx = 0;
hp                311 arch/sparc/mm/tsb.c 			hp->pgsz_mask = HV_PGSZ_MASK_BASE;
hp                315 arch/sparc/mm/tsb.c 			hp->pgsz_mask = HV_PGSZ_MASK_HUGE;
hp                321 arch/sparc/mm/tsb.c 		hp->tsb_base = tsb_paddr;
hp                322 arch/sparc/mm/tsb.c 		hp->resv = 0;
hp                 96 drivers/acpi/dock.c 	if (!adev->hp)
hp                102 drivers/acpi/dock.c 		fixup = adev->hp->fixup;
hp                111 drivers/acpi/dock.c 		uevent = adev->hp->uevent;
hp                120 drivers/acpi/dock.c 		notify = adev->hp->notify;
hp                 82 drivers/acpi/scan.c 				struct acpi_hotplug_context *hp,
hp                 87 drivers/acpi/scan.c 	hp->notify = notify;
hp                 88 drivers/acpi/scan.c 	hp->uevent = uevent;
hp                 89 drivers/acpi/scan.c 	acpi_set_hp_context(adev, hp);
hp                414 drivers/acpi/scan.c 		notify = adev->hp ? adev->hp->notify : NULL;
hp                 43 drivers/ata/libata-acpi.c 	struct acpi_hotplug_context hp;
hp                 50 drivers/ata/libata-acpi.c #define ata_hotplug_data(context) (container_of((context), struct ata_acpi_hotplug_context, hp)->data)
hp                137 drivers/ata/libata-acpi.c 	struct ata_device *dev = ata_hotplug_data(adev->hp).dev;
hp                144 drivers/ata/libata-acpi.c 	ata_acpi_handle_hotplug(ata_hotplug_data(adev->hp).ap, NULL, event);
hp                169 drivers/ata/libata-acpi.c 	ata_acpi_uevent(ata_hotplug_data(adev->hp).ap, NULL, event);
hp                174 drivers/ata/libata-acpi.c 	struct ata_device *dev = ata_hotplug_data(adev->hp).dev;
hp                194 drivers/ata/libata-acpi.c 	if (!adev || adev->hp)
hp                202 drivers/ata/libata-acpi.c 	acpi_initialize_hp_context(adev, &context->hp, ata_acpi_ap_notify_dock,
hp                236 drivers/ata/libata-acpi.c 	if (!adev || adev->hp)
hp                244 drivers/ata/libata-acpi.c 	acpi_initialize_hp_context(adev, &context->hp, ata_acpi_dev_notify_dock,
hp                978 drivers/block/sunvdc.c 	struct mdesc_handle *hp;
hp                985 drivers/block/sunvdc.c 	hp = mdesc_grab();
hp               1023 drivers/block/sunvdc.c 	ldc_timeout = mdesc_get_property(hp, vdev->mp, "vdc-timeout", NULL);
hp               1055 drivers/block/sunvdc.c 	mdesc_release(hp);
hp               1069 drivers/block/sunvdc.c 	mdesc_release(hp);
hp                 76 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                 86 drivers/char/agp/hp-agp.c 	hp->io_tlb_ps = readq(hp->ioc_regs+HP_ZX1_TCNFG);
hp                 87 drivers/char/agp/hp-agp.c 	switch (hp->io_tlb_ps) {
hp                 88 drivers/char/agp/hp-agp.c 		case 0: hp->io_tlb_shift = 12; break;
hp                 89 drivers/char/agp/hp-agp.c 		case 1: hp->io_tlb_shift = 13; break;
hp                 90 drivers/char/agp/hp-agp.c 		case 2: hp->io_tlb_shift = 14; break;
hp                 91 drivers/char/agp/hp-agp.c 		case 3: hp->io_tlb_shift = 16; break;
hp                 94 drivers/char/agp/hp-agp.c 			       "configuration 0x%x\n", hp->io_tlb_ps);
hp                 95 drivers/char/agp/hp-agp.c 			hp->gatt = NULL;
hp                 96 drivers/char/agp/hp-agp.c 			hp->gatt_entries = 0;
hp                 99 drivers/char/agp/hp-agp.c 	hp->io_page_size = 1 << hp->io_tlb_shift;
hp                100 drivers/char/agp/hp-agp.c 	hp->io_pages_per_kpage = PAGE_SIZE / hp->io_page_size;
hp                102 drivers/char/agp/hp-agp.c 	hp->iova_base = readq(hp->ioc_regs+HP_ZX1_IBASE) & ~0x1;
hp                103 drivers/char/agp/hp-agp.c 	hp->gart_base = hp->iova_base + HP_ZX1_IOVA_SIZE - HP_ZX1_GART_SIZE;
hp                105 drivers/char/agp/hp-agp.c 	hp->gart_size = HP_ZX1_GART_SIZE;
hp                106 drivers/char/agp/hp-agp.c 	hp->gatt_entries = hp->gart_size / hp->io_page_size;
hp                108 drivers/char/agp/hp-agp.c 	hp->io_pdir = phys_to_virt(readq(hp->ioc_regs+HP_ZX1_PDIR_BASE));
hp                109 drivers/char/agp/hp-agp.c 	hp->gatt = &hp->io_pdir[HP_ZX1_IOVA_TO_PDIR(hp->gart_base)];
hp                111 drivers/char/agp/hp-agp.c 	if (hp->gatt[0] != HP_ZX1_SBA_IOMMU_COOKIE) {
hp                113 drivers/char/agp/hp-agp.c 		hp->gatt = NULL;
hp                114 drivers/char/agp/hp-agp.c 		hp->gatt_entries = 0;
hp                126 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                134 drivers/char/agp/hp-agp.c 		hp->io_tlb_shift = 16;
hp                135 drivers/char/agp/hp-agp.c 		hp->io_tlb_ps = 3;
hp                137 drivers/char/agp/hp-agp.c 		hp->io_tlb_shift = 14;
hp                138 drivers/char/agp/hp-agp.c 		hp->io_tlb_ps = 2;
hp                140 drivers/char/agp/hp-agp.c 		hp->io_tlb_shift = 13;
hp                141 drivers/char/agp/hp-agp.c 		hp->io_tlb_ps = 1;
hp                143 drivers/char/agp/hp-agp.c 		hp->io_tlb_shift = 12;
hp                144 drivers/char/agp/hp-agp.c 		hp->io_tlb_ps = 0;
hp                146 drivers/char/agp/hp-agp.c 	hp->io_page_size = 1 << hp->io_tlb_shift;
hp                147 drivers/char/agp/hp-agp.c 	hp->io_pages_per_kpage = PAGE_SIZE / hp->io_page_size;
hp                149 drivers/char/agp/hp-agp.c 	hp->iova_base = HP_ZX1_IOVA_BASE;
hp                150 drivers/char/agp/hp-agp.c 	hp->gart_size = HP_ZX1_GART_SIZE;
hp                151 drivers/char/agp/hp-agp.c 	hp->gart_base = hp->iova_base + HP_ZX1_IOVA_SIZE - hp->gart_size;
hp                153 drivers/char/agp/hp-agp.c 	hp->gatt_entries = hp->gart_size / hp->io_page_size;
hp                154 drivers/char/agp/hp-agp.c 	hp->io_pdir_size = (HP_ZX1_IOVA_SIZE / hp->io_page_size) * sizeof(u64);
hp                162 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                164 drivers/char/agp/hp-agp.c 	hp->ioc_regs = ioremap(hpa, 1024);
hp                165 drivers/char/agp/hp-agp.c 	if (!hp->ioc_regs)
hp                172 drivers/char/agp/hp-agp.c 	hp->io_pdir_owner = (readq(hp->ioc_regs+HP_ZX1_IBASE) & 0x1) == 0;
hp                174 drivers/char/agp/hp-agp.c 	if (hp->io_pdir_owner)
hp                206 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                209 drivers/char/agp/hp-agp.c 	hp->lba_regs = ioremap(hpa, 256);
hp                210 drivers/char/agp/hp-agp.c 	if (!hp->lba_regs)
hp                213 drivers/char/agp/hp-agp.c 	hp->lba_cap_offset = hp_zx1_lba_find_capability(hp->lba_regs, PCI_CAP_ID_AGP);
hp                215 drivers/char/agp/hp-agp.c 	cap = readl(hp->lba_regs+hp->lba_cap_offset) & 0xff;
hp                218 drivers/char/agp/hp-agp.c 		       cap, hp->lba_cap_offset);
hp                219 drivers/char/agp/hp-agp.c 		iounmap(hp->lba_regs);
hp                240 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                242 drivers/char/agp/hp-agp.c 	agp_bridge->gart_bus_addr = hp->gart_base;
hp                243 drivers/char/agp/hp-agp.c 	agp_bridge->capndx = hp->lba_cap_offset;
hp                244 drivers/char/agp/hp-agp.c 	agp_bridge->mode = readl(hp->lba_regs+hp->lba_cap_offset+PCI_AGP_STATUS);
hp                246 drivers/char/agp/hp-agp.c 	if (hp->io_pdir_owner) {
hp                247 drivers/char/agp/hp-agp.c 		writel(virt_to_phys(hp->io_pdir), hp->ioc_regs+HP_ZX1_PDIR_BASE);
hp                248 drivers/char/agp/hp-agp.c 		readl(hp->ioc_regs+HP_ZX1_PDIR_BASE);
hp                249 drivers/char/agp/hp-agp.c 		writel(hp->io_tlb_ps, hp->ioc_regs+HP_ZX1_TCNFG);
hp                250 drivers/char/agp/hp-agp.c 		readl(hp->ioc_regs+HP_ZX1_TCNFG);
hp                251 drivers/char/agp/hp-agp.c 		writel((unsigned int)(~(HP_ZX1_IOVA_SIZE-1)), hp->ioc_regs+HP_ZX1_IMASK);
hp                252 drivers/char/agp/hp-agp.c 		readl(hp->ioc_regs+HP_ZX1_IMASK);
hp                253 drivers/char/agp/hp-agp.c 		writel(hp->iova_base|1, hp->ioc_regs+HP_ZX1_IBASE);
hp                254 drivers/char/agp/hp-agp.c 		readl(hp->ioc_regs+HP_ZX1_IBASE);
hp                255 drivers/char/agp/hp-agp.c 		writel(hp->iova_base|ilog2(HP_ZX1_IOVA_SIZE), hp->ioc_regs+HP_ZX1_PCOM);
hp                256 drivers/char/agp/hp-agp.c 		readl(hp->ioc_regs+HP_ZX1_PCOM);
hp                265 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                267 drivers/char/agp/hp-agp.c 	if (hp->ioc_regs) {
hp                268 drivers/char/agp/hp-agp.c 		if (hp->io_pdir_owner) {
hp                269 drivers/char/agp/hp-agp.c 			writeq(0, hp->ioc_regs+HP_ZX1_IBASE);
hp                270 drivers/char/agp/hp-agp.c 			readq(hp->ioc_regs+HP_ZX1_IBASE);
hp                272 drivers/char/agp/hp-agp.c 		iounmap(hp->ioc_regs);
hp                274 drivers/char/agp/hp-agp.c 	if (hp->lba_regs)
hp                275 drivers/char/agp/hp-agp.c 		iounmap(hp->lba_regs);
hp                281 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                283 drivers/char/agp/hp-agp.c 	writeq(hp->gart_base | ilog2(hp->gart_size), hp->ioc_regs+HP_ZX1_PCOM);
hp                284 drivers/char/agp/hp-agp.c 	readq(hp->ioc_regs+HP_ZX1_PCOM);
hp                290 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                293 drivers/char/agp/hp-agp.c 	if (hp->io_pdir_owner) {
hp                294 drivers/char/agp/hp-agp.c 		hp->io_pdir = (u64 *) __get_free_pages(GFP_KERNEL,
hp                295 drivers/char/agp/hp-agp.c 						get_order(hp->io_pdir_size));
hp                296 drivers/char/agp/hp-agp.c 		if (!hp->io_pdir) {
hp                299 drivers/char/agp/hp-agp.c 			hp->gatt = NULL;
hp                300 drivers/char/agp/hp-agp.c 			hp->gatt_entries = 0;
hp                303 drivers/char/agp/hp-agp.c 		memset(hp->io_pdir, 0, hp->io_pdir_size);
hp                305 drivers/char/agp/hp-agp.c 		hp->gatt = &hp->io_pdir[HP_ZX1_IOVA_TO_PDIR(hp->gart_base)];
hp                308 drivers/char/agp/hp-agp.c 	for (i = 0; i < hp->gatt_entries; i++) {
hp                309 drivers/char/agp/hp-agp.c 		hp->gatt[i] = (unsigned long) agp_bridge->scratch_page;
hp                318 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                320 drivers/char/agp/hp-agp.c 	if (hp->io_pdir_owner)
hp                321 drivers/char/agp/hp-agp.c 		free_pages((unsigned long) hp->io_pdir,
hp                322 drivers/char/agp/hp-agp.c 			    get_order(hp->io_pdir_size));
hp                324 drivers/char/agp/hp-agp.c 		hp->gatt[0] = HP_ZX1_SBA_IOMMU_COOKIE;
hp                331 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                341 drivers/char/agp/hp-agp.c 	io_pg_start = hp->io_pages_per_kpage * pg_start;
hp                342 drivers/char/agp/hp-agp.c 	io_pg_count = hp->io_pages_per_kpage * mem->page_count;
hp                343 drivers/char/agp/hp-agp.c 	if ((io_pg_start + io_pg_count) > hp->gatt_entries) {
hp                349 drivers/char/agp/hp-agp.c 		if (hp->gatt[j]) {
hp                365 drivers/char/agp/hp-agp.c 		     k < hp->io_pages_per_kpage;
hp                366 drivers/char/agp/hp-agp.c 		     k++, j++, paddr += hp->io_page_size) {
hp                367 drivers/char/agp/hp-agp.c 			hp->gatt[j] = HP_ZX1_PDIR_VALID_BIT | paddr;
hp                378 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                386 drivers/char/agp/hp-agp.c 	io_pg_start = hp->io_pages_per_kpage * pg_start;
hp                387 drivers/char/agp/hp-agp.c 	io_pg_count = hp->io_pages_per_kpage * mem->page_count;
hp                389 drivers/char/agp/hp-agp.c 		hp->gatt[i] = agp_bridge->scratch_page;
hp                405 drivers/char/agp/hp-agp.c 	struct _hp_private *hp = &hp_private;
hp                408 drivers/char/agp/hp-agp.c 	command = readl(hp->lba_regs+hp->lba_cap_offset+PCI_AGP_STATUS);
hp                412 drivers/char/agp/hp-agp.c 	writel(command, hp->lba_regs+hp->lba_cap_offset+PCI_AGP_COMMAND);
hp               1184 drivers/char/virtio_console.c static int notifier_add_vio(struct hvc_struct *hp, int data)
hp               1188 drivers/char/virtio_console.c 	port = find_port_by_vtermno(hp->vtermno);
hp               1192 drivers/char/virtio_console.c 	hp->irq_requested = 1;
hp               1198 drivers/char/virtio_console.c static void notifier_del_vio(struct hvc_struct *hp, int data)
hp               1200 drivers/char/virtio_console.c 	hp->irq_requested = 0;
hp                 49 drivers/clk/pxa/clk-pxa.c 	struct clk_fixed_factor hp;
hp                 65 drivers/clk/pxa/clk-pxa.c 		fix = &pclk->hp;
hp                107 drivers/clk/pxa/clk-pxa.c 		pxa_clk->hp = clks[i].hp;
hp                113 drivers/clk/pxa/clk-pxa.h 	struct clk_fixed_factor hp;
hp                124 drivers/clk/pxa/clk-pxa.h 	  .hp = { .mult = _mult_hp, .div = _div_hp },			\
hp                423 drivers/md/raid5.c 	struct hlist_head *hp = stripe_hash(conf, sh->sector);
hp                428 drivers/md/raid5.c 	hlist_add_head(&sh->hash, hp);
hp               3296 drivers/media/usb/pvrusb2/pvrusb2-hdw.c struct pvr2_stream *pvr2_hdw_get_video_stream(struct pvr2_hdw *hp)
hp               3298 drivers/media/usb/pvrusb2/pvrusb2-hdw.c 	return hp->vid_stream;
hp                183 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_hairpin *hp;
hp                454 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static int mlx5e_hairpin_create_transport(struct mlx5e_hairpin *hp)
hp                460 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	err = mlx5_core_alloc_transport_domain(hp->func_mdev, &hp->tdn);
hp                467 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	MLX5_SET(tirc, tirc, inline_rqn, hp->pair->rqn[0]);
hp                468 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	MLX5_SET(tirc, tirc, transport_domain, hp->tdn);
hp                470 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	err = mlx5_core_create_tir(hp->func_mdev, in, MLX5_ST_SZ_BYTES(create_tir_in), &hp->tirn);
hp                477 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5_core_dealloc_transport_domain(hp->func_mdev, hp->tdn);
hp                482 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static void mlx5e_hairpin_destroy_transport(struct mlx5e_hairpin *hp)
hp                484 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5_core_destroy_tir(hp->func_mdev, hp->tirn);
hp                485 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5_core_dealloc_transport_domain(hp->func_mdev, hp->tdn);
hp                488 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static void mlx5e_hairpin_fill_rqt_rqns(struct mlx5e_hairpin *hp, void *rqtc)
hp                491 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_priv *priv = hp->func_priv;
hp                495 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 				      hp->num_channels);
hp                502 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		rqn = hp->pair->rqn[ix];
hp                507 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static int mlx5e_hairpin_create_indirect_rqt(struct mlx5e_hairpin *hp)
hp                510 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_priv *priv = hp->func_priv;
hp                525 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_hairpin_fill_rqt_rqns(hp, rqtc);
hp                527 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	err = mlx5_core_create_rqt(mdev, in, inlen, &hp->indir_rqt.rqtn);
hp                529 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		hp->indir_rqt.enabled = true;
hp                535 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static int mlx5e_hairpin_create_indirect_tirs(struct mlx5e_hairpin *hp)
hp                537 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_priv *priv = hp->func_priv;
hp                548 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		MLX5_SET(tirc, tirc, transport_domain, hp->tdn);
hp                550 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		MLX5_SET(tirc, tirc, indirect_table, hp->indir_rqt.rqtn);
hp                553 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		err = mlx5_core_create_tir(hp->func_mdev, in,
hp                554 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 					   MLX5_ST_SZ_BYTES(create_tir_in), &hp->indir_tirn[tt]);
hp                556 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 			mlx5_core_warn(hp->func_mdev, "create indirect tirs failed, %d\n", err);
hp                564 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		mlx5_core_destroy_tir(hp->func_mdev, hp->indir_tirn[i]);
hp                568 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static void mlx5e_hairpin_destroy_indirect_tirs(struct mlx5e_hairpin *hp)
hp                573 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		mlx5_core_destroy_tir(hp->func_mdev, hp->indir_tirn[tt]);
hp                576 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static void mlx5e_hairpin_set_ttc_params(struct mlx5e_hairpin *hp,
hp                584 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	ttc_params->any_tt_tirn = hp->tirn;
hp                587 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		ttc_params->indir_tirn[tt] = hp->indir_tirn[tt];
hp                594 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static int mlx5e_hairpin_rss_init(struct mlx5e_hairpin *hp)
hp                596 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_priv *priv = hp->func_priv;
hp                600 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	err = mlx5e_hairpin_create_indirect_rqt(hp);
hp                604 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	err = mlx5e_hairpin_create_indirect_tirs(hp);
hp                608 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_hairpin_set_ttc_params(hp, &ttc_params);
hp                609 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	err = mlx5e_create_ttc_table(priv, &ttc_params, &hp->ttc);
hp                614 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		   hp->num_channels, hp->ttc.ft.t->id);
hp                619 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_hairpin_destroy_indirect_tirs(hp);
hp                621 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_destroy_rqt(priv, &hp->indir_rqt);
hp                626 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static void mlx5e_hairpin_rss_cleanup(struct mlx5e_hairpin *hp)
hp                628 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_priv *priv = hp->func_priv;
hp                630 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_destroy_ttc_table(priv, &hp->ttc);
hp                631 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_hairpin_destroy_indirect_tirs(hp);
hp                632 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_destroy_rqt(priv, &hp->indir_rqt);
hp                640 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_hairpin *hp;
hp                644 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	hp = kzalloc(sizeof(*hp), GFP_KERNEL);
hp                645 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	if (!hp)
hp                656 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	hp->pair = pair;
hp                657 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	hp->func_mdev = func_mdev;
hp                658 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	hp->func_priv = priv;
hp                659 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	hp->num_channels = params->num_channels;
hp                661 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	err = mlx5e_hairpin_create_transport(hp);
hp                665 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	if (hp->num_channels > 1) {
hp                666 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		err = mlx5e_hairpin_rss_init(hp);
hp                671 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	return hp;
hp                674 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_hairpin_destroy_transport(hp);
hp                676 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5_core_hairpin_destroy(hp->pair);
hp                678 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	kfree(hp);
hp                682 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c static void mlx5e_hairpin_destroy(struct mlx5e_hairpin *hp)
hp                684 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	if (hp->num_channels > 1)
hp                685 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		mlx5e_hairpin_rss_cleanup(hp);
hp                686 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5e_hairpin_destroy_transport(hp);
hp                687 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	mlx5_core_hairpin_destroy(hp->pair);
hp                688 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	kvfree(hp);
hp                722 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	if (!IS_ERR_OR_NULL(hpe->hp)) {
hp                724 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 			   dev_name(hpe->hp->pair->peer_mdev->device));
hp                726 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		mlx5e_hairpin_destroy(hpe->hp);
hp                780 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	struct mlx5e_hairpin *hp;
hp                805 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		if (IS_ERR(hpe->hp)) {
hp                849 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	hp = mlx5e_hairpin_create(priv, &params, peer_ifindex);
hp                850 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	hpe->hp = hp;
hp                852 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	if (IS_ERR(hp)) {
hp                853 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		err = PTR_ERR(hp);
hp                858 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		   hp->tirn, hp->pair->rqn[0],
hp                859 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		   dev_name(hp->pair->peer_mdev->device),
hp                860 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		   hp->pair->sqn[0], match_prio, params.log_data_size, params.log_num_packets);
hp                863 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 	if (hpe->hp->num_channels > 1) {
hp                865 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		flow->nic_attr->hairpin_ft = hpe->hp->ttc.ft.t;
hp                867 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		flow->nic_attr->hairpin_tirn = hpe->hp->tirn;
hp               4072 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 		if (!IS_ERR_OR_NULL(hpe->hp) && hpe->peer_vhca_id == peer_vhca_id)
hp               4073 drivers/net/ethernet/mellanox/mlx5/core/en_tc.c 			hpe->hp->pair->peer_gone = true;
hp                342 drivers/net/ethernet/mellanox/mlx5/core/transobj.c static int mlx5_hairpin_create_queues(struct mlx5_hairpin *hp,
hp                347 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	for (i = 0; i < hp->num_channels; i++) {
hp                348 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		err = mlx5_hairpin_create_rq(hp->func_mdev, params, &hp->rqn[i]);
hp                353 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	for (i = 0; i < hp->num_channels; i++) {
hp                354 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		err = mlx5_hairpin_create_sq(hp->peer_mdev, params, &hp->sqn[i]);
hp                363 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		mlx5_core_destroy_sq(hp->peer_mdev, hp->sqn[j]);
hp                364 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	i = hp->num_channels;
hp                367 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		mlx5_core_destroy_rq(hp->func_mdev, hp->rqn[j]);
hp                371 drivers/net/ethernet/mellanox/mlx5/core/transobj.c static void mlx5_hairpin_destroy_queues(struct mlx5_hairpin *hp)
hp                375 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	for (i = 0; i < hp->num_channels; i++) {
hp                376 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		mlx5_core_destroy_rq(hp->func_mdev, hp->rqn[i]);
hp                377 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		if (!hp->peer_gone)
hp                378 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 			mlx5_core_destroy_sq(hp->peer_mdev, hp->sqn[i]);
hp                424 drivers/net/ethernet/mellanox/mlx5/core/transobj.c static int mlx5_hairpin_pair_queues(struct mlx5_hairpin *hp)
hp                429 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	for (i = 0; i < hp->num_channels; i++) {
hp                430 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		err = mlx5_hairpin_modify_sq(hp->peer_mdev, hp->sqn[i],
hp                432 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 					     MLX5_CAP_GEN(hp->func_mdev, vhca_id), hp->rqn[i]);
hp                438 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	for (i = 0; i < hp->num_channels; i++) {
hp                439 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		err = mlx5_hairpin_modify_rq(hp->func_mdev, hp->rqn[i],
hp                441 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 					     MLX5_CAP_GEN(hp->peer_mdev, vhca_id), hp->sqn[i]);
hp                450 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		mlx5_hairpin_modify_rq(hp->func_mdev, hp->rqn[j], MLX5_RQC_STATE_RDY,
hp                452 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	i = hp->num_channels;
hp                455 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		mlx5_hairpin_modify_sq(hp->peer_mdev, hp->sqn[j], MLX5_SQC_STATE_RDY,
hp                460 drivers/net/ethernet/mellanox/mlx5/core/transobj.c static void mlx5_hairpin_unpair_queues(struct mlx5_hairpin *hp)
hp                465 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	for (i = 0; i < hp->num_channels; i++)
hp                466 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		mlx5_hairpin_modify_rq(hp->func_mdev, hp->rqn[i], MLX5_RQC_STATE_RDY,
hp                470 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	if (hp->peer_gone)
hp                472 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	for (i = 0; i < hp->num_channels; i++)
hp                473 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 		mlx5_hairpin_modify_sq(hp->peer_mdev, hp->sqn[i], MLX5_SQC_STATE_RDY,
hp                482 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	struct mlx5_hairpin *hp;
hp                485 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	size = sizeof(*hp) + params->num_channels * 2 * sizeof(u32);
hp                486 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	hp = kzalloc(size, GFP_KERNEL);
hp                487 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	if (!hp)
hp                490 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	hp->func_mdev = func_mdev;
hp                491 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	hp->peer_mdev = peer_mdev;
hp                492 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	hp->num_channels = params->num_channels;
hp                494 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	hp->rqn = (void *)hp + sizeof(*hp);
hp                495 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	hp->sqn = hp->rqn + params->num_channels;
hp                498 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	err = mlx5_hairpin_create_queues(hp, params);
hp                502 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	err = mlx5_hairpin_pair_queues(hp);
hp                506 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	return hp;
hp                509 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	mlx5_hairpin_destroy_queues(hp);
hp                511 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	kfree(hp);
hp                515 drivers/net/ethernet/mellanox/mlx5/core/transobj.c void mlx5_core_hairpin_destroy(struct mlx5_hairpin *hp)
hp                517 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	mlx5_hairpin_unpair_queues(hp);
hp                518 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	mlx5_hairpin_destroy_queues(hp);
hp                519 drivers/net/ethernet/mellanox/mlx5/core/transobj.c 	kfree(hp);
hp                167 drivers/net/ethernet/sun/ldmvsw.c static struct vnet *vsw_get_vnet(struct mdesc_handle *hp,
hp                178 drivers/net/ethernet/sun/ldmvsw.c 	mdesc_for_each_arc(a, hp, port_node, MDESC_ARC_TYPE_BACK) {
hp                179 drivers/net/ethernet/sun/ldmvsw.c 		u64 target = mdesc_arc_target(hp, a);
hp                182 drivers/net/ethernet/sun/ldmvsw.c 		name = mdesc_get_property(hp, target, "name", NULL);
hp                186 drivers/net/ethernet/sun/ldmvsw.c 		local_mac = mdesc_get_property(hp, target,
hp                188 drivers/net/ethernet/sun/ldmvsw.c 		cfghandle = mdesc_get_property(hp, target,
hp                281 drivers/net/ethernet/sun/ldmvsw.c 	struct mdesc_handle *hp;
hp                291 drivers/net/ethernet/sun/ldmvsw.c 	hp = mdesc_grab();
hp                293 drivers/net/ethernet/sun/ldmvsw.c 	rmac = mdesc_get_property(hp, vdev->mp, remote_macaddr_prop, &len);
hp                297 drivers/net/ethernet/sun/ldmvsw.c 		mdesc_release(hp);
hp                301 drivers/net/ethernet/sun/ldmvsw.c 	port_id = mdesc_get_property(hp, vdev->mp, id_prop, NULL);
hp                305 drivers/net/ethernet/sun/ldmvsw.c 		mdesc_release(hp);
hp                310 drivers/net/ethernet/sun/ldmvsw.c 	vp = vsw_get_vnet(hp, vdev->mp, &handle);
hp                314 drivers/net/ethernet/sun/ldmvsw.c 		mdesc_release(hp);
hp                318 drivers/net/ethernet/sun/ldmvsw.c 	mdesc_release(hp);
hp                111 drivers/net/ethernet/sun/sunhme.c static __inline__ void tx_add_log(struct happy_meal *hp, unsigned int a, unsigned int s)
hp                119 drivers/net/ethernet/sun/sunhme.c 	tlp->tx_new = hp->tx_new;
hp                120 drivers/net/ethernet/sun/sunhme.c 	tlp->tx_old = hp->tx_old;
hp                139 drivers/net/ethernet/sun/sunhme.c static __inline__ void tx_dump_ring(struct happy_meal *hp)
hp                141 drivers/net/ethernet/sun/sunhme.c 	struct hmeal_init_block *hb = hp->happy_block;
hp                155 drivers/net/ethernet/sun/sunhme.c #define tx_add_log(hp, a, s)		do { } while(0)
hp                157 drivers/net/ethernet/sun/sunhme.c #define tx_dump_ring(hp)		do { } while(0)
hp                305 drivers/net/ethernet/sun/sunhme.c static inline u32 hme_read_desc32(struct happy_meal *hp, hme32 *p)
hp                322 drivers/net/ethernet/sun/sunhme.c static void BB_PUT_BIT(struct happy_meal *hp, void __iomem *tregs, int bit)
hp                324 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBDATA, bit);
hp                325 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBCLOCK, 0);
hp                326 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBCLOCK, 1);
hp                330 drivers/net/ethernet/sun/sunhme.c static u32 BB_GET_BIT(struct happy_meal *hp, void __iomem *tregs, int internal)
hp                334 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBCLOCK, 0);
hp                335 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBCLOCK, 1);
hp                336 drivers/net/ethernet/sun/sunhme.c 	ret = hme_read32(hp, tregs + TCVR_CFG);
hp                346 drivers/net/ethernet/sun/sunhme.c static u32 BB_GET_BIT2(struct happy_meal *hp, void __iomem *tregs, int internal)
hp                350 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBCLOCK, 0);
hp                352 drivers/net/ethernet/sun/sunhme.c 	retval = hme_read32(hp, tregs + TCVR_CFG);
hp                357 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBCLOCK, 1);
hp                364 drivers/net/ethernet/sun/sunhme.c static int happy_meal_bb_read(struct happy_meal *hp,
hp                374 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBOENAB, 1);
hp                378 drivers/net/ethernet/sun/sunhme.c 		BB_PUT_BIT(hp, tregs, 1);
hp                381 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 0);
hp                382 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 1);
hp                383 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 1);
hp                384 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 0);
hp                387 drivers/net/ethernet/sun/sunhme.c 	tmp = hp->paddr & 0xff;
hp                389 drivers/net/ethernet/sun/sunhme.c 		BB_PUT_BIT(hp, tregs, ((tmp >> i) & 1));
hp                394 drivers/net/ethernet/sun/sunhme.c 		BB_PUT_BIT(hp, tregs, ((tmp >> i) & 1));
hp                397 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBOENAB, 0);
hp                400 drivers/net/ethernet/sun/sunhme.c 	(void) BB_GET_BIT2(hp, tregs, (hp->tcvr_type == internal));
hp                402 drivers/net/ethernet/sun/sunhme.c 		retval |= BB_GET_BIT2(hp, tregs, (hp->tcvr_type == internal));
hp                403 drivers/net/ethernet/sun/sunhme.c 	(void) BB_GET_BIT2(hp, tregs, (hp->tcvr_type == internal));
hp                404 drivers/net/ethernet/sun/sunhme.c 	(void) BB_GET_BIT2(hp, tregs, (hp->tcvr_type == internal));
hp                405 drivers/net/ethernet/sun/sunhme.c 	(void) BB_GET_BIT2(hp, tregs, (hp->tcvr_type == internal));
hp                410 drivers/net/ethernet/sun/sunhme.c static void happy_meal_bb_write(struct happy_meal *hp,
hp                420 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBOENAB, 1);
hp                424 drivers/net/ethernet/sun/sunhme.c 		BB_PUT_BIT(hp, tregs, 1);
hp                427 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 0);
hp                428 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 1);
hp                429 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 0);
hp                430 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 1);
hp                433 drivers/net/ethernet/sun/sunhme.c 	tmp = (hp->paddr & 0xff);
hp                435 drivers/net/ethernet/sun/sunhme.c 		BB_PUT_BIT(hp, tregs, ((tmp >> i) & 1));
hp                440 drivers/net/ethernet/sun/sunhme.c 		BB_PUT_BIT(hp, tregs, ((tmp >> i) & 1));
hp                443 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 1);
hp                444 drivers/net/ethernet/sun/sunhme.c 	BB_PUT_BIT(hp, tregs, 0);
hp                447 drivers/net/ethernet/sun/sunhme.c 		BB_PUT_BIT(hp, tregs, ((value >> i) & 1));
hp                450 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_BBOENAB, 0);
hp                455 drivers/net/ethernet/sun/sunhme.c static int happy_meal_tcvr_read(struct happy_meal *hp,
hp                462 drivers/net/ethernet/sun/sunhme.c 	if (hp->tcvr_type == none) {
hp                467 drivers/net/ethernet/sun/sunhme.c 	if (!(hp->happy_flags & HFLAG_FENABLE)) {
hp                469 drivers/net/ethernet/sun/sunhme.c 		return happy_meal_bb_read(hp, tregs, reg);
hp                472 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_FRAME,
hp                473 drivers/net/ethernet/sun/sunhme.c 		    (FRAME_READ | (hp->paddr << 23) | ((reg & 0xff) << 18)));
hp                474 drivers/net/ethernet/sun/sunhme.c 	while (!(hme_read32(hp, tregs + TCVR_FRAME) & 0x10000) && --tries)
hp                480 drivers/net/ethernet/sun/sunhme.c 	retval = hme_read32(hp, tregs + TCVR_FRAME) & 0xffff;
hp                487 drivers/net/ethernet/sun/sunhme.c static void happy_meal_tcvr_write(struct happy_meal *hp,
hp                496 drivers/net/ethernet/sun/sunhme.c 	if (!(hp->happy_flags & HFLAG_FENABLE)) {
hp                497 drivers/net/ethernet/sun/sunhme.c 		happy_meal_bb_write(hp, tregs, reg, value);
hp                502 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_FRAME,
hp                503 drivers/net/ethernet/sun/sunhme.c 		    (FRAME_WRITE | (hp->paddr << 23) |
hp                505 drivers/net/ethernet/sun/sunhme.c 	while (!(hme_read32(hp, tregs + TCVR_FRAME) & 0x10000) && --tries)
hp                547 drivers/net/ethernet/sun/sunhme.c static int try_next_permutation(struct happy_meal *hp, void __iomem *tregs)
hp                549 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmcr = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp                554 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmcr & BMCR_FULLDPLX) {
hp                555 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr &= ~(BMCR_FULLDPLX);
hp                556 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp                561 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmcr & BMCR_SPEED100) {
hp                562 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr &= ~(BMCR_SPEED100);
hp                563 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp                571 drivers/net/ethernet/sun/sunhme.c static void display_link_mode(struct happy_meal *hp, void __iomem *tregs)
hp                573 drivers/net/ethernet/sun/sunhme.c 	printk(KERN_INFO "%s: Link is up using ", hp->dev->name);
hp                574 drivers/net/ethernet/sun/sunhme.c 	if (hp->tcvr_type == external)
hp                579 drivers/net/ethernet/sun/sunhme.c 	hp->sw_lpa = happy_meal_tcvr_read(hp, tregs, MII_LPA);
hp                580 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_lpa & (LPA_100HALF | LPA_100FULL)) {
hp                581 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_lpa & LPA_100FULL)
hp                586 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_lpa & LPA_10FULL)
hp                593 drivers/net/ethernet/sun/sunhme.c static void display_forced_link_mode(struct happy_meal *hp, void __iomem *tregs)
hp                595 drivers/net/ethernet/sun/sunhme.c 	printk(KERN_INFO "%s: Link has been forced up using ", hp->dev->name);
hp                596 drivers/net/ethernet/sun/sunhme.c 	if (hp->tcvr_type == external)
hp                601 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmcr = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp                602 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmcr & BMCR_SPEED100)
hp                606 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmcr & BMCR_FULLDPLX)
hp                612 drivers/net/ethernet/sun/sunhme.c static int set_happy_link_modes(struct happy_meal *hp, void __iomem *tregs)
hp                619 drivers/net/ethernet/sun/sunhme.c 	if (hp->timer_state == arbwait) {
hp                620 drivers/net/ethernet/sun/sunhme.c 		hp->sw_lpa = happy_meal_tcvr_read(hp, tregs, MII_LPA);
hp                621 drivers/net/ethernet/sun/sunhme.c 		if (!(hp->sw_lpa & (LPA_10HALF | LPA_10FULL | LPA_100HALF | LPA_100FULL)))
hp                623 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_lpa & LPA_100FULL)
hp                625 drivers/net/ethernet/sun/sunhme.c 		else if (hp->sw_lpa & LPA_100HALF)
hp                627 drivers/net/ethernet/sun/sunhme.c 		else if (hp->sw_lpa & LPA_10FULL)
hp                633 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp                634 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_bmcr & BMCR_FULLDPLX)
hp                648 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, hp->bigmacregs + BMAC_TXCFG,
hp                649 drivers/net/ethernet/sun/sunhme.c 		    hme_read32(hp, hp->bigmacregs + BMAC_TXCFG) &
hp                651 drivers/net/ethernet/sun/sunhme.c 	while (hme_read32(hp, hp->bigmacregs + BMAC_TXCFG) & BIGMAC_TXCFG_ENABLE)
hp                654 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags |= HFLAG_FULL;
hp                655 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, hp->bigmacregs + BMAC_TXCFG,
hp                656 drivers/net/ethernet/sun/sunhme.c 			    hme_read32(hp, hp->bigmacregs + BMAC_TXCFG) |
hp                659 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags &= ~(HFLAG_FULL);
hp                660 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, hp->bigmacregs + BMAC_TXCFG,
hp                661 drivers/net/ethernet/sun/sunhme.c 			    hme_read32(hp, hp->bigmacregs + BMAC_TXCFG) &
hp                664 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, hp->bigmacregs + BMAC_TXCFG,
hp                665 drivers/net/ethernet/sun/sunhme.c 		    hme_read32(hp, hp->bigmacregs + BMAC_TXCFG) |
hp                672 drivers/net/ethernet/sun/sunhme.c static int happy_meal_init(struct happy_meal *hp);
hp                674 drivers/net/ethernet/sun/sunhme.c static int is_lucent_phy(struct happy_meal *hp)
hp                676 drivers/net/ethernet/sun/sunhme.c 	void __iomem *tregs = hp->tcvregs;
hp                680 drivers/net/ethernet/sun/sunhme.c 	mr2 = happy_meal_tcvr_read(hp, tregs, 2);
hp                681 drivers/net/ethernet/sun/sunhme.c 	mr3 = happy_meal_tcvr_read(hp, tregs, 3);
hp                691 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = from_timer(hp, t, happy_timer);
hp                692 drivers/net/ethernet/sun/sunhme.c 	void __iomem *tregs = hp->tcvregs;
hp                695 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp                697 drivers/net/ethernet/sun/sunhme.c 	hp->timer_ticks++;
hp                698 drivers/net/ethernet/sun/sunhme.c 	switch(hp->timer_state) {
hp                703 drivers/net/ethernet/sun/sunhme.c 		if (hp->timer_ticks >= 10) {
hp                706 drivers/net/ethernet/sun/sunhme.c 			hp->sw_bmcr = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp                708 drivers/net/ethernet/sun/sunhme.c 			       hp->dev->name);
hp                709 drivers/net/ethernet/sun/sunhme.c 			hp->sw_bmcr = BMCR_SPEED100;
hp                710 drivers/net/ethernet/sun/sunhme.c 			happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp                712 drivers/net/ethernet/sun/sunhme.c 			if (!is_lucent_phy(hp)) {
hp                717 drivers/net/ethernet/sun/sunhme.c 				hp->sw_csconfig = happy_meal_tcvr_read(hp, tregs, DP83840_CSCONFIG);
hp                718 drivers/net/ethernet/sun/sunhme.c 				hp->sw_csconfig &= ~(CSCONFIG_TCVDISAB);
hp                719 drivers/net/ethernet/sun/sunhme.c 				happy_meal_tcvr_write(hp, tregs, DP83840_CSCONFIG, hp->sw_csconfig);
hp                721 drivers/net/ethernet/sun/sunhme.c 			hp->timer_state = ltrywait;
hp                722 drivers/net/ethernet/sun/sunhme.c 			hp->timer_ticks = 0;
hp                726 drivers/net/ethernet/sun/sunhme.c 			hp->sw_bmsr = happy_meal_tcvr_read(hp, tregs, MII_BMSR);
hp                727 drivers/net/ethernet/sun/sunhme.c 			if (hp->sw_bmsr & BMSR_ANEGCOMPLETE) {
hp                731 drivers/net/ethernet/sun/sunhme.c 				ret = set_happy_link_modes(hp, tregs);
hp                743 drivers/net/ethernet/sun/sunhme.c 				hp->timer_state = lupwait;
hp                757 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmsr = happy_meal_tcvr_read(hp, tregs, MII_BMSR);
hp                758 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_bmsr & BMSR_LSTATUS) {
hp                762 drivers/net/ethernet/sun/sunhme.c 			display_link_mode(hp, tregs);
hp                763 drivers/net/ethernet/sun/sunhme.c 			hp->timer_state = asleep;
hp                766 drivers/net/ethernet/sun/sunhme.c 			if (hp->timer_ticks >= 10) {
hp                768 drivers/net/ethernet/sun/sunhme.c 				       "not completely up.\n", hp->dev->name);
hp                769 drivers/net/ethernet/sun/sunhme.c 				hp->timer_ticks = 0;
hp                783 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmsr = happy_meal_tcvr_read(hp, tregs, MII_BMSR);
hp                784 drivers/net/ethernet/sun/sunhme.c 		hp->sw_csconfig = happy_meal_tcvr_read(hp, tregs, DP83840_CSCONFIG);
hp                785 drivers/net/ethernet/sun/sunhme.c 		if (hp->timer_ticks == 1) {
hp                786 drivers/net/ethernet/sun/sunhme.c 			if (!is_lucent_phy(hp)) {
hp                790 drivers/net/ethernet/sun/sunhme.c 				hp->sw_csconfig |= CSCONFIG_TCVDISAB;
hp                791 drivers/net/ethernet/sun/sunhme.c 				happy_meal_tcvr_write(hp, tregs,
hp                792 drivers/net/ethernet/sun/sunhme.c 						      DP83840_CSCONFIG, hp->sw_csconfig);
hp                797 drivers/net/ethernet/sun/sunhme.c 		if (hp->timer_ticks == 2) {
hp                798 drivers/net/ethernet/sun/sunhme.c 			if (!is_lucent_phy(hp)) {
hp                799 drivers/net/ethernet/sun/sunhme.c 				hp->sw_csconfig &= ~(CSCONFIG_TCVDISAB);
hp                800 drivers/net/ethernet/sun/sunhme.c 				happy_meal_tcvr_write(hp, tregs,
hp                801 drivers/net/ethernet/sun/sunhme.c 						      DP83840_CSCONFIG, hp->sw_csconfig);
hp                806 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_bmsr & BMSR_LSTATUS) {
hp                808 drivers/net/ethernet/sun/sunhme.c 			display_forced_link_mode(hp, tregs);
hp                809 drivers/net/ethernet/sun/sunhme.c 			set_happy_link_modes(hp, tregs); /* XXX error? then what? */
hp                810 drivers/net/ethernet/sun/sunhme.c 			hp->timer_state = asleep;
hp                813 drivers/net/ethernet/sun/sunhme.c 			if (hp->timer_ticks >= 4) { /* 6 seconds or so... */
hp                816 drivers/net/ethernet/sun/sunhme.c 				ret = try_next_permutation(hp, tregs);
hp                824 drivers/net/ethernet/sun/sunhme.c 					       hp->dev->name);
hp                826 drivers/net/ethernet/sun/sunhme.c 					ret = happy_meal_init(hp);
hp                830 drivers/net/ethernet/sun/sunhme.c 						       "Happy Meal.\n", hp->dev->name);
hp                834 drivers/net/ethernet/sun/sunhme.c 				if (!is_lucent_phy(hp)) {
hp                835 drivers/net/ethernet/sun/sunhme.c 					hp->sw_csconfig = happy_meal_tcvr_read(hp, tregs,
hp                837 drivers/net/ethernet/sun/sunhme.c 					hp->sw_csconfig |= CSCONFIG_TCVDISAB;
hp                838 drivers/net/ethernet/sun/sunhme.c 					happy_meal_tcvr_write(hp, tregs,
hp                839 drivers/net/ethernet/sun/sunhme.c 							      DP83840_CSCONFIG, hp->sw_csconfig);
hp                841 drivers/net/ethernet/sun/sunhme.c 				hp->timer_ticks = 0;
hp                853 drivers/net/ethernet/sun/sunhme.c 		       hp->dev->name);
hp                855 drivers/net/ethernet/sun/sunhme.c 		hp->timer_ticks = 0;
hp                856 drivers/net/ethernet/sun/sunhme.c 		hp->timer_state = asleep; /* foo on you */
hp                861 drivers/net/ethernet/sun/sunhme.c 		hp->happy_timer.expires = jiffies + ((12 * HZ)/10); /* 1.2 sec. */
hp                862 drivers/net/ethernet/sun/sunhme.c 		add_timer(&hp->happy_timer);
hp                866 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp                873 drivers/net/ethernet/sun/sunhme.c static void happy_meal_tx_reset(struct happy_meal *hp, void __iomem *bregs)
hp                880 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_TXSWRESET, 0);
hp                881 drivers/net/ethernet/sun/sunhme.c 	while ((hme_read32(hp, bregs + BMAC_TXSWRESET) & 1) && --tries)
hp                893 drivers/net/ethernet/sun/sunhme.c static void happy_meal_rx_reset(struct happy_meal *hp, void __iomem *bregs)
hp                900 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_RXSWRESET, 0);
hp                901 drivers/net/ethernet/sun/sunhme.c 	while ((hme_read32(hp, bregs + BMAC_RXSWRESET) & 1) && --tries)
hp                915 drivers/net/ethernet/sun/sunhme.c static void happy_meal_stop(struct happy_meal *hp, void __iomem *gregs)
hp                922 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, gregs + GREG_SWRESET, GREG_RESET_ALL);
hp                923 drivers/net/ethernet/sun/sunhme.c 	while (hme_read32(hp, gregs + GREG_SWRESET) && --tries)
hp                935 drivers/net/ethernet/sun/sunhme.c static void happy_meal_get_counters(struct happy_meal *hp, void __iomem *bregs)
hp                937 drivers/net/ethernet/sun/sunhme.c 	struct net_device_stats *stats = &hp->dev->stats;
hp                939 drivers/net/ethernet/sun/sunhme.c 	stats->rx_crc_errors += hme_read32(hp, bregs + BMAC_RCRCECTR);
hp                940 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_RCRCECTR, 0);
hp                942 drivers/net/ethernet/sun/sunhme.c 	stats->rx_frame_errors += hme_read32(hp, bregs + BMAC_UNALECTR);
hp                943 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_UNALECTR, 0);
hp                945 drivers/net/ethernet/sun/sunhme.c 	stats->rx_length_errors += hme_read32(hp, bregs + BMAC_GLECTR);
hp                946 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_GLECTR, 0);
hp                948 drivers/net/ethernet/sun/sunhme.c 	stats->tx_aborted_errors += hme_read32(hp, bregs + BMAC_EXCTR);
hp                951 drivers/net/ethernet/sun/sunhme.c 		(hme_read32(hp, bregs + BMAC_EXCTR) +
hp                952 drivers/net/ethernet/sun/sunhme.c 		 hme_read32(hp, bregs + BMAC_LTCTR));
hp                953 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_EXCTR, 0);
hp                954 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_LTCTR, 0);
hp                958 drivers/net/ethernet/sun/sunhme.c static void happy_meal_poll_stop(struct happy_meal *hp, void __iomem *tregs)
hp                963 drivers/net/ethernet/sun/sunhme.c 	if ((hp->happy_flags & (HFLAG_POLLENABLE | HFLAG_POLL)) !=
hp                971 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_IMASK, 0xffff);
hp                975 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_CFG,
hp                976 drivers/net/ethernet/sun/sunhme.c 		    hme_read32(hp, tregs + TCVR_CFG) & ~(TCV_CFG_PENABLE));
hp                979 drivers/net/ethernet/sun/sunhme.c 	hp->happy_flags &= ~(HFLAG_POLL);
hp                993 drivers/net/ethernet/sun/sunhme.c static int happy_meal_tcvr_reset(struct happy_meal *hp, void __iomem *tregs)
hp                998 drivers/net/ethernet/sun/sunhme.c 	tconfig = hme_read32(hp, tregs + TCVR_CFG);
hp               1000 drivers/net/ethernet/sun/sunhme.c 	if (hp->tcvr_type == external) {
hp               1002 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, tregs + TCVR_CFG, tconfig & ~(TCV_CFG_PSELECT));
hp               1003 drivers/net/ethernet/sun/sunhme.c 		hp->tcvr_type = internal;
hp               1004 drivers/net/ethernet/sun/sunhme.c 		hp->paddr = TCV_PADDR_ITX;
hp               1006 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs, MII_BMCR,
hp               1008 drivers/net/ethernet/sun/sunhme.c 		result = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp               1014 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, tregs + TCVR_CFG, tconfig | TCV_CFG_PSELECT);
hp               1015 drivers/net/ethernet/sun/sunhme.c 		hp->tcvr_type = external;
hp               1016 drivers/net/ethernet/sun/sunhme.c 		hp->paddr = TCV_PADDR_ETX;
hp               1020 drivers/net/ethernet/sun/sunhme.c 			hme_write32(hp, tregs + TCVR_CFG, (tconfig | TCV_CFG_PSELECT));
hp               1022 drivers/net/ethernet/sun/sunhme.c 			happy_meal_tcvr_write(hp, tregs, MII_BMCR,
hp               1024 drivers/net/ethernet/sun/sunhme.c 			result = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp               1030 drivers/net/ethernet/sun/sunhme.c 			hme_write32(hp, tregs + TCVR_CFG, (tconfig & ~(TCV_CFG_PSELECT)));
hp               1031 drivers/net/ethernet/sun/sunhme.c 			hp->tcvr_type = internal;
hp               1032 drivers/net/ethernet/sun/sunhme.c 			hp->paddr = TCV_PADDR_ITX;
hp               1037 drivers/net/ethernet/sun/sunhme.c 	happy_meal_tcvr_write(hp, tregs, MII_BMCR, BMCR_RESET);
hp               1040 drivers/net/ethernet/sun/sunhme.c 		result = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp               1043 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr = result;
hp               1055 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmsr      = happy_meal_tcvr_read(hp, tregs, MII_BMSR);
hp               1056 drivers/net/ethernet/sun/sunhme.c 	hp->sw_physid1   = happy_meal_tcvr_read(hp, tregs, MII_PHYSID1);
hp               1057 drivers/net/ethernet/sun/sunhme.c 	hp->sw_physid2   = happy_meal_tcvr_read(hp, tregs, MII_PHYSID2);
hp               1058 drivers/net/ethernet/sun/sunhme.c 	hp->sw_advertise = happy_meal_tcvr_read(hp, tregs, MII_ADVERTISE);
hp               1061 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmcr &= ~(BMCR_ISOLATE);
hp               1062 drivers/net/ethernet/sun/sunhme.c 	happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp               1066 drivers/net/ethernet/sun/sunhme.c 		result = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp               1078 drivers/net/ethernet/sun/sunhme.c 	if (!is_lucent_phy(hp)) {
hp               1079 drivers/net/ethernet/sun/sunhme.c 		result = happy_meal_tcvr_read(hp, tregs,
hp               1081 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs,
hp               1091 drivers/net/ethernet/sun/sunhme.c static void happy_meal_transceiver_check(struct happy_meal *hp, void __iomem *tregs)
hp               1093 drivers/net/ethernet/sun/sunhme.c 	unsigned long tconfig = hme_read32(hp, tregs + TCVR_CFG);
hp               1096 drivers/net/ethernet/sun/sunhme.c 	if (hp->happy_flags & HFLAG_POLL) {
hp               1099 drivers/net/ethernet/sun/sunhme.c 		if (hp->tcvr_type == internal) {
hp               1102 drivers/net/ethernet/sun/sunhme.c 				happy_meal_poll_stop(hp, tregs);
hp               1103 drivers/net/ethernet/sun/sunhme.c 				hp->paddr = TCV_PADDR_ETX;
hp               1104 drivers/net/ethernet/sun/sunhme.c 				hp->tcvr_type = external;
hp               1108 drivers/net/ethernet/sun/sunhme.c 				hme_write32(hp, tregs + TCVR_CFG, tconfig);
hp               1111 drivers/net/ethernet/sun/sunhme.c 			if (hp->tcvr_type == external) {
hp               1113 drivers/net/ethernet/sun/sunhme.c 				if (!(hme_read32(hp, tregs + TCVR_STATUS) >> 16)) {
hp               1115 drivers/net/ethernet/sun/sunhme.c 					happy_meal_poll_stop(hp, tregs);
hp               1116 drivers/net/ethernet/sun/sunhme.c 					hp->paddr = TCV_PADDR_ITX;
hp               1117 drivers/net/ethernet/sun/sunhme.c 					hp->tcvr_type = internal;
hp               1119 drivers/net/ethernet/sun/sunhme.c 					hme_write32(hp, tregs + TCVR_CFG,
hp               1120 drivers/net/ethernet/sun/sunhme.c 						    hme_read32(hp, tregs + TCVR_CFG) &
hp               1129 drivers/net/ethernet/sun/sunhme.c 		u32 reread = hme_read32(hp, tregs + TCVR_CFG);
hp               1134 drivers/net/ethernet/sun/sunhme.c 			hme_write32(hp, tregs + TCVR_CFG, tconfig | TCV_CFG_PSELECT);
hp               1135 drivers/net/ethernet/sun/sunhme.c 			hp->paddr = TCV_PADDR_ETX;
hp               1136 drivers/net/ethernet/sun/sunhme.c 			hp->tcvr_type = external;
hp               1140 drivers/net/ethernet/sun/sunhme.c 				hme_write32(hp, tregs + TCVR_CFG,
hp               1142 drivers/net/ethernet/sun/sunhme.c 				hp->paddr = TCV_PADDR_ITX;
hp               1143 drivers/net/ethernet/sun/sunhme.c 				hp->tcvr_type = internal;
hp               1147 drivers/net/ethernet/sun/sunhme.c 				hp->tcvr_type = none; /* Grrr... */
hp               1198 drivers/net/ethernet/sun/sunhme.c static void happy_meal_clean_rings(struct happy_meal *hp)
hp               1203 drivers/net/ethernet/sun/sunhme.c 		if (hp->rx_skbs[i] != NULL) {
hp               1204 drivers/net/ethernet/sun/sunhme.c 			struct sk_buff *skb = hp->rx_skbs[i];
hp               1208 drivers/net/ethernet/sun/sunhme.c 			rxd = &hp->happy_block->happy_meal_rxd[i];
hp               1209 drivers/net/ethernet/sun/sunhme.c 			dma_addr = hme_read_desc32(hp, &rxd->rx_addr);
hp               1210 drivers/net/ethernet/sun/sunhme.c 			dma_unmap_single(hp->dma_dev, dma_addr,
hp               1213 drivers/net/ethernet/sun/sunhme.c 			hp->rx_skbs[i] = NULL;
hp               1218 drivers/net/ethernet/sun/sunhme.c 		if (hp->tx_skbs[i] != NULL) {
hp               1219 drivers/net/ethernet/sun/sunhme.c 			struct sk_buff *skb = hp->tx_skbs[i];
hp               1224 drivers/net/ethernet/sun/sunhme.c 			hp->tx_skbs[i] = NULL;
hp               1227 drivers/net/ethernet/sun/sunhme.c 				txd = &hp->happy_block->happy_meal_txd[i];
hp               1228 drivers/net/ethernet/sun/sunhme.c 				dma_addr = hme_read_desc32(hp, &txd->tx_addr);
hp               1230 drivers/net/ethernet/sun/sunhme.c 					dma_unmap_single(hp->dma_dev, dma_addr,
hp               1231 drivers/net/ethernet/sun/sunhme.c 							 (hme_read_desc32(hp, &txd->tx_flags)
hp               1235 drivers/net/ethernet/sun/sunhme.c 					dma_unmap_page(hp->dma_dev, dma_addr,
hp               1236 drivers/net/ethernet/sun/sunhme.c 							 (hme_read_desc32(hp, &txd->tx_flags)
hp               1250 drivers/net/ethernet/sun/sunhme.c static void happy_meal_init_rings(struct happy_meal *hp)
hp               1252 drivers/net/ethernet/sun/sunhme.c 	struct hmeal_init_block *hb = hp->happy_block;
hp               1256 drivers/net/ethernet/sun/sunhme.c 	hp->rx_new = hp->rx_old = hp->tx_new = hp->tx_old = 0;
hp               1260 drivers/net/ethernet/sun/sunhme.c 	happy_meal_clean_rings(hp);
hp               1270 drivers/net/ethernet/sun/sunhme.c 			hme_write_rxd(hp, &hb->happy_meal_rxd[i], 0, 0);
hp               1273 drivers/net/ethernet/sun/sunhme.c 		hp->rx_skbs[i] = skb;
hp               1277 drivers/net/ethernet/sun/sunhme.c 		mapping = dma_map_single(hp->dma_dev, skb->data, RX_BUF_ALLOC_SIZE,
hp               1279 drivers/net/ethernet/sun/sunhme.c 		if (dma_mapping_error(hp->dma_dev, mapping)) {
hp               1281 drivers/net/ethernet/sun/sunhme.c 			hme_write_rxd(hp, &hb->happy_meal_rxd[i], 0, 0);
hp               1284 drivers/net/ethernet/sun/sunhme.c 		hme_write_rxd(hp, &hb->happy_meal_rxd[i],
hp               1292 drivers/net/ethernet/sun/sunhme.c 		hme_write_txd(hp, &hb->happy_meal_txd[i], 0, 0);
hp               1299 drivers/net/ethernet/sun/sunhme.c happy_meal_begin_auto_negotiation(struct happy_meal *hp,
hp               1306 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmsr      = happy_meal_tcvr_read(hp, tregs, MII_BMSR);
hp               1307 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmcr      = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp               1308 drivers/net/ethernet/sun/sunhme.c 	hp->sw_physid1   = happy_meal_tcvr_read(hp, tregs, MII_PHYSID1);
hp               1309 drivers/net/ethernet/sun/sunhme.c 	hp->sw_physid2   = happy_meal_tcvr_read(hp, tregs, MII_PHYSID2);
hp               1313 drivers/net/ethernet/sun/sunhme.c 	hp->sw_advertise = happy_meal_tcvr_read(hp, tregs, MII_ADVERTISE);
hp               1316 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_bmsr & BMSR_10HALF)
hp               1317 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise |= (ADVERTISE_10HALF);
hp               1319 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise &= ~(ADVERTISE_10HALF);
hp               1321 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_bmsr & BMSR_10FULL)
hp               1322 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise |= (ADVERTISE_10FULL);
hp               1324 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise &= ~(ADVERTISE_10FULL);
hp               1325 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_bmsr & BMSR_100HALF)
hp               1326 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise |= (ADVERTISE_100HALF);
hp               1328 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise &= ~(ADVERTISE_100HALF);
hp               1329 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_bmsr & BMSR_100FULL)
hp               1330 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise |= (ADVERTISE_100FULL);
hp               1332 drivers/net/ethernet/sun/sunhme.c 			hp->sw_advertise &= ~(ADVERTISE_100FULL);
hp               1333 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs, MII_ADVERTISE, hp->sw_advertise);
hp               1342 drivers/net/ethernet/sun/sunhme.c 		ASD(("%s: Advertising [ ", hp->dev->name));
hp               1343 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_advertise & ADVERTISE_10HALF)
hp               1345 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_advertise & ADVERTISE_10FULL)
hp               1347 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_advertise & ADVERTISE_100HALF)
hp               1349 drivers/net/ethernet/sun/sunhme.c 		if (hp->sw_advertise & ADVERTISE_100FULL)
hp               1354 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr |= BMCR_ANENABLE;
hp               1355 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp               1358 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr |= BMCR_ANRESTART;
hp               1359 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp               1365 drivers/net/ethernet/sun/sunhme.c 			hp->sw_bmcr = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp               1366 drivers/net/ethernet/sun/sunhme.c 			if (!(hp->sw_bmcr & BMCR_ANRESTART))
hp               1372 drivers/net/ethernet/sun/sunhme.c 			       "BMCR=0x%04x\n", hp->dev->name, hp->sw_bmcr);
hp               1374 drivers/net/ethernet/sun/sunhme.c 			       hp->dev->name);
hp               1377 drivers/net/ethernet/sun/sunhme.c 			hp->timer_state = arbwait;
hp               1390 drivers/net/ethernet/sun/sunhme.c 			hp->sw_bmcr = BMCR_SPEED100;
hp               1393 drivers/net/ethernet/sun/sunhme.c 				hp->sw_bmcr = BMCR_SPEED100;
hp               1395 drivers/net/ethernet/sun/sunhme.c 				hp->sw_bmcr = 0;
hp               1397 drivers/net/ethernet/sun/sunhme.c 				hp->sw_bmcr |= BMCR_FULLDPLX;
hp               1399 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp               1401 drivers/net/ethernet/sun/sunhme.c 		if (!is_lucent_phy(hp)) {
hp               1406 drivers/net/ethernet/sun/sunhme.c 			hp->sw_csconfig = happy_meal_tcvr_read(hp, tregs,
hp               1408 drivers/net/ethernet/sun/sunhme.c 			hp->sw_csconfig &= ~(CSCONFIG_TCVDISAB);
hp               1409 drivers/net/ethernet/sun/sunhme.c 			happy_meal_tcvr_write(hp, tregs, DP83840_CSCONFIG,
hp               1410 drivers/net/ethernet/sun/sunhme.c 					      hp->sw_csconfig);
hp               1412 drivers/net/ethernet/sun/sunhme.c 		hp->timer_state = ltrywait;
hp               1415 drivers/net/ethernet/sun/sunhme.c 	hp->timer_ticks = 0;
hp               1416 drivers/net/ethernet/sun/sunhme.c 	hp->happy_timer.expires = jiffies + (12 * HZ)/10;  /* 1.2 sec. */
hp               1417 drivers/net/ethernet/sun/sunhme.c 	add_timer(&hp->happy_timer);
hp               1421 drivers/net/ethernet/sun/sunhme.c static int happy_meal_init(struct happy_meal *hp)
hp               1423 drivers/net/ethernet/sun/sunhme.c 	void __iomem *gregs        = hp->gregs;
hp               1424 drivers/net/ethernet/sun/sunhme.c 	void __iomem *etxregs      = hp->etxregs;
hp               1425 drivers/net/ethernet/sun/sunhme.c 	void __iomem *erxregs      = hp->erxregs;
hp               1426 drivers/net/ethernet/sun/sunhme.c 	void __iomem *bregs        = hp->bigmacregs;
hp               1427 drivers/net/ethernet/sun/sunhme.c 	void __iomem *tregs        = hp->tcvregs;
hp               1429 drivers/net/ethernet/sun/sunhme.c 	unsigned char *e = &hp->dev->dev_addr[0];
hp               1432 drivers/net/ethernet/sun/sunhme.c 	del_timer(&hp->happy_timer);
hp               1435 drivers/net/ethernet/sun/sunhme.c 	     hp->happy_flags));
hp               1436 drivers/net/ethernet/sun/sunhme.c 	if (!(hp->happy_flags & HFLAG_INIT)) {
hp               1438 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags |= HFLAG_INIT;
hp               1439 drivers/net/ethernet/sun/sunhme.c 		happy_meal_get_counters(hp, bregs);
hp               1444 drivers/net/ethernet/sun/sunhme.c 	happy_meal_poll_stop(hp, tregs);
hp               1448 drivers/net/ethernet/sun/sunhme.c 	happy_meal_stop(hp, gregs);
hp               1452 drivers/net/ethernet/sun/sunhme.c 	happy_meal_init_rings(hp);
hp               1456 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, tregs + TCVR_IMASK)));
hp               1457 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_IMASK, 0xffff);
hp               1460 drivers/net/ethernet/sun/sunhme.c 	if (hp->happy_flags & HFLAG_FENABLE) {
hp               1462 drivers/net/ethernet/sun/sunhme.c 		     hme_read32(hp, tregs + TCVR_CFG)));
hp               1463 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, tregs + TCVR_CFG,
hp               1464 drivers/net/ethernet/sun/sunhme.c 			    hme_read32(hp, tregs + TCVR_CFG) & ~(TCV_CFG_BENABLE));
hp               1467 drivers/net/ethernet/sun/sunhme.c 		     hme_read32(hp, tregs + TCVR_CFG)));
hp               1468 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, tregs + TCVR_CFG,
hp               1469 drivers/net/ethernet/sun/sunhme.c 			    hme_read32(hp, tregs + TCVR_CFG) | TCV_CFG_BENABLE);
hp               1474 drivers/net/ethernet/sun/sunhme.c 	happy_meal_transceiver_check(hp, tregs);
hp               1478 drivers/net/ethernet/sun/sunhme.c 	switch(hp->tcvr_type) {
hp               1487 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_XIFCFG, 0);
hp               1493 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_XIFCFG, BIGMAC_XCFG_MIIDISAB);
hp               1497 drivers/net/ethernet/sun/sunhme.c 	if (happy_meal_tcvr_reset(hp, tregs))
hp               1502 drivers/net/ethernet/sun/sunhme.c 	happy_meal_tx_reset(hp, bregs);
hp               1503 drivers/net/ethernet/sun/sunhme.c 	happy_meal_rx_reset(hp, bregs);
hp               1507 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_JSIZE, DEFAULT_JAMSIZE);
hp               1508 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_IGAP1, DEFAULT_IPG1);
hp               1509 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_IGAP2, DEFAULT_IPG2);
hp               1515 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_RSEED, ((e[5] | e[4]<<8)&0x3ff));
hp               1517 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_MACADDR2, ((e[4] << 8) | e[5]));
hp               1518 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_MACADDR1, ((e[2] << 8) | e[3]));
hp               1519 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_MACADDR0, ((e[0] << 8) | e[1]));
hp               1522 drivers/net/ethernet/sun/sunhme.c 	if ((hp->dev->flags & IFF_ALLMULTI) ||
hp               1523 drivers/net/ethernet/sun/sunhme.c 	    (netdev_mc_count(hp->dev) > 64)) {
hp               1524 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE0, 0xffff);
hp               1525 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE1, 0xffff);
hp               1526 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE2, 0xffff);
hp               1527 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE3, 0xffff);
hp               1528 drivers/net/ethernet/sun/sunhme.c 	} else if ((hp->dev->flags & IFF_PROMISC) == 0) {
hp               1534 drivers/net/ethernet/sun/sunhme.c 		netdev_for_each_mc_addr(ha, hp->dev) {
hp               1539 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE0, hash_table[0]);
hp               1540 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE1, hash_table[1]);
hp               1541 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE2, hash_table[2]);
hp               1542 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE3, hash_table[3]);
hp               1544 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE3, 0);
hp               1545 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE2, 0);
hp               1546 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE1, 0);
hp               1547 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE0, 0);
hp               1552 drivers/net/ethernet/sun/sunhme.c 	     ((__u32)hp->hblock_dvma + hblock_offset(happy_meal_rxd, 0)),
hp               1553 drivers/net/ethernet/sun/sunhme.c 	     ((__u32)hp->hblock_dvma + hblock_offset(happy_meal_txd, 0))));
hp               1554 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, erxregs + ERX_RING,
hp               1555 drivers/net/ethernet/sun/sunhme.c 		    ((__u32)hp->hblock_dvma + hblock_offset(happy_meal_rxd, 0)));
hp               1556 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, etxregs + ETX_RING,
hp               1557 drivers/net/ethernet/sun/sunhme.c 		    ((__u32)hp->hblock_dvma + hblock_offset(happy_meal_txd, 0)));
hp               1564 drivers/net/ethernet/sun/sunhme.c 	if (hme_read32(hp, erxregs + ERX_RING) !=
hp               1565 drivers/net/ethernet/sun/sunhme.c 	    ((__u32)hp->hblock_dvma + hblock_offset(happy_meal_rxd, 0)))
hp               1566 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, erxregs + ERX_RING,
hp               1567 drivers/net/ethernet/sun/sunhme.c 			    ((__u32)hp->hblock_dvma + hblock_offset(happy_meal_rxd, 0))
hp               1572 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, gregs + GREG_CFG)));
hp               1576 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, gregs + GREG_CFG, GREG_CFG_BURST64);
hp               1578 drivers/net/ethernet/sun/sunhme.c 	if ((hp->happy_bursts & DMA_BURST64) &&
hp               1579 drivers/net/ethernet/sun/sunhme.c 	    ((hp->happy_flags & HFLAG_PCI) != 0
hp               1591 drivers/net/ethernet/sun/sunhme.c 		if ((hp->happy_flags & HFLAG_PCI) == 0) {
hp               1592 drivers/net/ethernet/sun/sunhme.c 			struct platform_device *op = hp->happy_dev;
hp               1595 drivers/net/ethernet/sun/sunhme.c 						hp->happy_bursts);
hp               1602 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, gregs + GREG_CFG, gcfg);
hp               1603 drivers/net/ethernet/sun/sunhme.c 	} else if (hp->happy_bursts & DMA_BURST32) {
hp               1605 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, gregs + GREG_CFG, GREG_CFG_BURST32);
hp               1606 drivers/net/ethernet/sun/sunhme.c 	} else if (hp->happy_bursts & DMA_BURST16) {
hp               1608 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, gregs + GREG_CFG, GREG_CFG_BURST16);
hp               1611 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, gregs + GREG_CFG, 0);
hp               1617 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, gregs + GREG_IMASK,
hp               1623 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, etxregs + ETX_RSIZE)));
hp               1624 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, etxregs + ETX_RSIZE, (TX_RING_SIZE >> ETX_RSIZE_SHIFT) - 1);
hp               1628 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, etxregs + ETX_CFG)));
hp               1629 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, etxregs + ETX_CFG,
hp               1630 drivers/net/ethernet/sun/sunhme.c 		    hme_read32(hp, etxregs + ETX_CFG) | ETX_CFG_DMAENABLE);
hp               1638 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, erxregs + ERX_CFG)));
hp               1639 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, erxregs + ERX_CFG, ERX_CFG_DEFAULT(RX_OFFSET));
hp               1640 drivers/net/ethernet/sun/sunhme.c 	regtmp = hme_read32(hp, erxregs + ERX_CFG);
hp               1641 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, erxregs + ERX_CFG, ERX_CFG_DEFAULT(RX_OFFSET));
hp               1642 drivers/net/ethernet/sun/sunhme.c 	if (hme_read32(hp, erxregs + ERX_CFG) != ERX_CFG_DEFAULT(RX_OFFSET)) {
hp               1651 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, bregs + BMAC_RXCFG)));
hp               1653 drivers/net/ethernet/sun/sunhme.c 	if (hp->dev->flags & IFF_PROMISC)
hp               1655 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_RXCFG, rxcfg);
hp               1663 drivers/net/ethernet/sun/sunhme.c 	if (hp->happy_flags & HFLAG_FULL)
hp               1669 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_TXCFG, regtmp /*| BIGMAC_TXCFG_DGIVEUP*/);
hp               1672 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_ALIMIT, 16);
hp               1678 drivers/net/ethernet/sun/sunhme.c 	if (hp->happy_flags & HFLAG_LANCE)
hp               1682 drivers/net/ethernet/sun/sunhme.c 	if (hp->tcvr_type == external)
hp               1686 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, bregs + BMAC_XIFCFG)));
hp               1687 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_XIFCFG, regtmp);
hp               1691 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, bregs + BMAC_TXCFG),
hp               1692 drivers/net/ethernet/sun/sunhme.c 	     hme_read32(hp, bregs + BMAC_RXCFG)));
hp               1695 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_TXMAX, ETH_FRAME_LEN + 8);
hp               1696 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_RXMAX, ETH_FRAME_LEN + 8);
hp               1698 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_TXCFG,
hp               1699 drivers/net/ethernet/sun/sunhme.c 		    hme_read32(hp, bregs + BMAC_TXCFG) | BIGMAC_TXCFG_ENABLE);
hp               1700 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, bregs + BMAC_RXCFG,
hp               1701 drivers/net/ethernet/sun/sunhme.c 		    hme_read32(hp, bregs + BMAC_RXCFG) | BIGMAC_RXCFG_ENABLE);
hp               1704 drivers/net/ethernet/sun/sunhme.c 	happy_meal_begin_auto_negotiation(hp, tregs, NULL);
hp               1711 drivers/net/ethernet/sun/sunhme.c static void happy_meal_set_initial_advertisement(struct happy_meal *hp)
hp               1713 drivers/net/ethernet/sun/sunhme.c 	void __iomem *tregs	= hp->tcvregs;
hp               1714 drivers/net/ethernet/sun/sunhme.c 	void __iomem *bregs	= hp->bigmacregs;
hp               1715 drivers/net/ethernet/sun/sunhme.c 	void __iomem *gregs	= hp->gregs;
hp               1717 drivers/net/ethernet/sun/sunhme.c 	happy_meal_stop(hp, gregs);
hp               1718 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, tregs + TCVR_IMASK, 0xffff);
hp               1719 drivers/net/ethernet/sun/sunhme.c 	if (hp->happy_flags & HFLAG_FENABLE)
hp               1720 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, tregs + TCVR_CFG,
hp               1721 drivers/net/ethernet/sun/sunhme.c 			    hme_read32(hp, tregs + TCVR_CFG) & ~(TCV_CFG_BENABLE));
hp               1723 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, tregs + TCVR_CFG,
hp               1724 drivers/net/ethernet/sun/sunhme.c 			    hme_read32(hp, tregs + TCVR_CFG) | TCV_CFG_BENABLE);
hp               1725 drivers/net/ethernet/sun/sunhme.c 	happy_meal_transceiver_check(hp, tregs);
hp               1726 drivers/net/ethernet/sun/sunhme.c 	switch(hp->tcvr_type) {
hp               1730 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_XIFCFG, 0);
hp               1733 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_XIFCFG, BIGMAC_XCFG_MIIDISAB);
hp               1736 drivers/net/ethernet/sun/sunhme.c 	if (happy_meal_tcvr_reset(hp, tregs))
hp               1740 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmsr      = happy_meal_tcvr_read(hp, tregs, MII_BMSR);
hp               1741 drivers/net/ethernet/sun/sunhme.c 	hp->sw_advertise = happy_meal_tcvr_read(hp, tregs, MII_ADVERTISE);
hp               1744 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmsr & BMSR_10HALF)
hp               1745 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise |= (ADVERTISE_10HALF);
hp               1747 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise &= ~(ADVERTISE_10HALF);
hp               1749 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmsr & BMSR_10FULL)
hp               1750 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise |= (ADVERTISE_10FULL);
hp               1752 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise &= ~(ADVERTISE_10FULL);
hp               1753 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmsr & BMSR_100HALF)
hp               1754 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise |= (ADVERTISE_100HALF);
hp               1756 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise &= ~(ADVERTISE_100HALF);
hp               1757 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmsr & BMSR_100FULL)
hp               1758 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise |= (ADVERTISE_100FULL);
hp               1760 drivers/net/ethernet/sun/sunhme.c 		hp->sw_advertise &= ~(ADVERTISE_100FULL);
hp               1763 drivers/net/ethernet/sun/sunhme.c 	happy_meal_tcvr_write(hp, tregs, MII_ADVERTISE, hp->sw_advertise);
hp               1771 drivers/net/ethernet/sun/sunhme.c static int happy_meal_is_not_so_happy(struct happy_meal *hp, u32 status)
hp               1783 drivers/net/ethernet/sun/sunhme.c 		       hp->dev->name, status);
hp               1788 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_DEBUG "%s: Happy Meal receive FIFO overflow.\n", hp->dev->name);
hp               1793 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_ERR "%s: Happy Meal BigMAC SQE test failed.\n", hp->dev->name);
hp               1800 drivers/net/ethernet/sun/sunhme.c 		       hp->dev->name);
hp               1808 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_ERR "%s: Happy Meal MAX Packet size error.\n", hp->dev->name);
hp               1820 drivers/net/ethernet/sun/sunhme.c 		       hp->dev->name);
hp               1825 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_ERR "%s: Happy Meal rx DMA errors [ ", hp->dev->name);
hp               1841 drivers/net/ethernet/sun/sunhme.c 		       hp->dev->name);
hp               1847 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_ERR "%s: Happy Meal MIF interrupt.\n", hp->dev->name);
hp               1853 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_ERR "%s: Happy Meal tx DMA errors [ ", hp->dev->name);
hp               1871 drivers/net/ethernet/sun/sunhme.c 		       hp->dev->name,
hp               1877 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_NOTICE "%s: Resetting...\n", hp->dev->name);
hp               1878 drivers/net/ethernet/sun/sunhme.c 		happy_meal_init(hp);
hp               1885 drivers/net/ethernet/sun/sunhme.c static void happy_meal_mif_interrupt(struct happy_meal *hp)
hp               1887 drivers/net/ethernet/sun/sunhme.c 	void __iomem *tregs = hp->tcvregs;
hp               1889 drivers/net/ethernet/sun/sunhme.c 	printk(KERN_INFO "%s: Link status change.\n", hp->dev->name);
hp               1890 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmcr = happy_meal_tcvr_read(hp, tregs, MII_BMCR);
hp               1891 drivers/net/ethernet/sun/sunhme.c 	hp->sw_lpa = happy_meal_tcvr_read(hp, tregs, MII_LPA);
hp               1894 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_lpa & LPA_100FULL) {
hp               1895 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_INFO "%s: Switching to 100Mbps at full duplex.", hp->dev->name);
hp               1896 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr |= (BMCR_FULLDPLX | BMCR_SPEED100);
hp               1897 drivers/net/ethernet/sun/sunhme.c 	} else if (hp->sw_lpa & LPA_100HALF) {
hp               1898 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_INFO "%s: Switching to 100MBps at half duplex.", hp->dev->name);
hp               1899 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr |= BMCR_SPEED100;
hp               1900 drivers/net/ethernet/sun/sunhme.c 	} else if (hp->sw_lpa & LPA_10FULL) {
hp               1901 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_INFO "%s: Switching to 10MBps at full duplex.", hp->dev->name);
hp               1902 drivers/net/ethernet/sun/sunhme.c 		hp->sw_bmcr |= BMCR_FULLDPLX;
hp               1904 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_INFO "%s: Using 10Mbps at half duplex.", hp->dev->name);
hp               1906 drivers/net/ethernet/sun/sunhme.c 	happy_meal_tcvr_write(hp, tregs, MII_BMCR, hp->sw_bmcr);
hp               1909 drivers/net/ethernet/sun/sunhme.c 	happy_meal_poll_stop(hp, tregs);
hp               1919 drivers/net/ethernet/sun/sunhme.c static void happy_meal_tx(struct happy_meal *hp)
hp               1921 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal_txd *txbase = &hp->happy_block->happy_meal_txd[0];
hp               1923 drivers/net/ethernet/sun/sunhme.c 	struct net_device *dev = hp->dev;
hp               1926 drivers/net/ethernet/sun/sunhme.c 	elem = hp->tx_old;
hp               1928 drivers/net/ethernet/sun/sunhme.c 	while (elem != hp->tx_new) {
hp               1935 drivers/net/ethernet/sun/sunhme.c 		flags = hme_read_desc32(hp, &this->tx_flags);
hp               1938 drivers/net/ethernet/sun/sunhme.c 		skb = hp->tx_skbs[elem];
hp               1944 drivers/net/ethernet/sun/sunhme.c 			flags = hme_read_desc32(hp, &txbase[last].tx_flags);
hp               1948 drivers/net/ethernet/sun/sunhme.c 		hp->tx_skbs[elem] = NULL;
hp               1952 drivers/net/ethernet/sun/sunhme.c 			dma_addr = hme_read_desc32(hp, &this->tx_addr);
hp               1953 drivers/net/ethernet/sun/sunhme.c 			dma_len = hme_read_desc32(hp, &this->tx_flags);
hp               1957 drivers/net/ethernet/sun/sunhme.c 				dma_unmap_single(hp->dma_dev, dma_addr, dma_len, DMA_TO_DEVICE);
hp               1959 drivers/net/ethernet/sun/sunhme.c 				dma_unmap_page(hp->dma_dev, dma_addr, dma_len, DMA_TO_DEVICE);
hp               1968 drivers/net/ethernet/sun/sunhme.c 	hp->tx_old = elem;
hp               1972 drivers/net/ethernet/sun/sunhme.c 	    TX_BUFFS_AVAIL(hp) > (MAX_SKB_FRAGS + 1))
hp               1991 drivers/net/ethernet/sun/sunhme.c static void happy_meal_rx(struct happy_meal *hp, struct net_device *dev)
hp               1993 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal_rxd *rxbase = &hp->happy_block->happy_meal_rxd[0];
hp               1995 drivers/net/ethernet/sun/sunhme.c 	int elem = hp->rx_new, drops = 0;
hp               2000 drivers/net/ethernet/sun/sunhme.c 	while (!((flags = hme_read_desc32(hp, &this->rx_flags)) & RXFLAG_OWN)) {
hp               2004 drivers/net/ethernet/sun/sunhme.c 		u32 dma_addr = hme_read_desc32(hp, &this->rx_addr);
hp               2022 drivers/net/ethernet/sun/sunhme.c 			hme_write_rxd(hp, this,
hp               2027 drivers/net/ethernet/sun/sunhme.c 		skb = hp->rx_skbs[elem];
hp               2039 drivers/net/ethernet/sun/sunhme.c 			mapping = dma_map_single(hp->dma_dev, new_skb->data,
hp               2042 drivers/net/ethernet/sun/sunhme.c 			if (unlikely(dma_mapping_error(hp->dma_dev, mapping))) {
hp               2048 drivers/net/ethernet/sun/sunhme.c 			dma_unmap_single(hp->dma_dev, dma_addr, RX_BUF_ALLOC_SIZE, DMA_FROM_DEVICE);
hp               2049 drivers/net/ethernet/sun/sunhme.c 			hp->rx_skbs[elem] = new_skb;
hp               2050 drivers/net/ethernet/sun/sunhme.c 			hme_write_rxd(hp, this,
hp               2067 drivers/net/ethernet/sun/sunhme.c 			dma_sync_single_for_cpu(hp->dma_dev, dma_addr, len, DMA_FROM_DEVICE);
hp               2069 drivers/net/ethernet/sun/sunhme.c 			dma_sync_single_for_device(hp->dma_dev, dma_addr, len, DMA_FROM_DEVICE);
hp               2071 drivers/net/ethernet/sun/sunhme.c 			hme_write_rxd(hp, this,
hp               2092 drivers/net/ethernet/sun/sunhme.c 	hp->rx_new = elem;
hp               2094 drivers/net/ethernet/sun/sunhme.c 		printk(KERN_INFO "%s: Memory squeeze, deferring packet.\n", hp->dev->name);
hp               2101 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp  = netdev_priv(dev);
hp               2102 drivers/net/ethernet/sun/sunhme.c 	u32 happy_status       = hme_read32(hp, hp->gregs + GREG_STAT);
hp               2106 drivers/net/ethernet/sun/sunhme.c 	spin_lock(&hp->happy_lock);
hp               2110 drivers/net/ethernet/sun/sunhme.c 		if (happy_meal_is_not_so_happy(hp, /* un- */ happy_status))
hp               2116 drivers/net/ethernet/sun/sunhme.c 		happy_meal_mif_interrupt(hp);
hp               2121 drivers/net/ethernet/sun/sunhme.c 		happy_meal_tx(hp);
hp               2126 drivers/net/ethernet/sun/sunhme.c 		happy_meal_rx(hp, dev);
hp               2131 drivers/net/ethernet/sun/sunhme.c 	spin_unlock(&hp->happy_lock);
hp               2144 drivers/net/ethernet/sun/sunhme.c 		struct happy_meal *hp  = netdev_priv(dev);
hp               2145 drivers/net/ethernet/sun/sunhme.c 		u32 happy_status       = hme_read32(hp, hp->gregs + GREG_STAT);
hp               2155 drivers/net/ethernet/sun/sunhme.c 		spin_lock(&hp->happy_lock);
hp               2159 drivers/net/ethernet/sun/sunhme.c 			if (happy_meal_is_not_so_happy(hp, happy_status))
hp               2165 drivers/net/ethernet/sun/sunhme.c 			happy_meal_mif_interrupt(hp);
hp               2170 drivers/net/ethernet/sun/sunhme.c 			happy_meal_tx(hp);
hp               2175 drivers/net/ethernet/sun/sunhme.c 			happy_meal_rx(hp, dev);
hp               2179 drivers/net/ethernet/sun/sunhme.c 		spin_unlock(&hp->happy_lock);
hp               2189 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2197 drivers/net/ethernet/sun/sunhme.c 	if ((hp->happy_flags & (HFLAG_QUATTRO|HFLAG_PCI)) != HFLAG_QUATTRO) {
hp               2198 drivers/net/ethernet/sun/sunhme.c 		res = request_irq(hp->irq, happy_meal_interrupt, IRQF_SHARED,
hp               2203 drivers/net/ethernet/sun/sunhme.c 			       hp->irq);
hp               2211 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2212 drivers/net/ethernet/sun/sunhme.c 	res = happy_meal_init(hp);
hp               2213 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2215 drivers/net/ethernet/sun/sunhme.c 	if (res && ((hp->happy_flags & (HFLAG_QUATTRO|HFLAG_PCI)) != HFLAG_QUATTRO))
hp               2216 drivers/net/ethernet/sun/sunhme.c 		free_irq(hp->irq, dev);
hp               2222 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2224 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2225 drivers/net/ethernet/sun/sunhme.c 	happy_meal_stop(hp, hp->gregs);
hp               2226 drivers/net/ethernet/sun/sunhme.c 	happy_meal_clean_rings(hp);
hp               2229 drivers/net/ethernet/sun/sunhme.c 	del_timer(&hp->happy_timer);
hp               2231 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2237 drivers/net/ethernet/sun/sunhme.c 	if ((hp->happy_flags & (HFLAG_QUATTRO|HFLAG_PCI)) != HFLAG_QUATTRO)
hp               2238 drivers/net/ethernet/sun/sunhme.c 		free_irq(hp->irq, dev);
hp               2251 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2256 drivers/net/ethernet/sun/sunhme.c 		hme_read32(hp, hp->gregs + GREG_STAT),
hp               2257 drivers/net/ethernet/sun/sunhme.c 		hme_read32(hp, hp->etxregs + ETX_CFG),
hp               2258 drivers/net/ethernet/sun/sunhme.c 		hme_read32(hp, hp->bigmacregs + BMAC_TXCFG));
hp               2260 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2261 drivers/net/ethernet/sun/sunhme.c 	happy_meal_init(hp);
hp               2262 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2267 drivers/net/ethernet/sun/sunhme.c static void unmap_partial_tx_skb(struct happy_meal *hp, u32 first_mapping,
hp               2270 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal_txd *txbase = &hp->happy_block->happy_meal_txd[0];
hp               2272 drivers/net/ethernet/sun/sunhme.c 	dma_unmap_single(hp->dma_dev, first_mapping, first_len, DMA_TO_DEVICE);
hp               2279 drivers/net/ethernet/sun/sunhme.c 		addr = hme_read_desc32(hp, &this->tx_addr);
hp               2280 drivers/net/ethernet/sun/sunhme.c 		len = hme_read_desc32(hp, &this->tx_flags);
hp               2282 drivers/net/ethernet/sun/sunhme.c 		dma_unmap_page(hp->dma_dev, addr, len, DMA_TO_DEVICE);
hp               2289 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2303 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2305 drivers/net/ethernet/sun/sunhme.c  	if (TX_BUFFS_AVAIL(hp) <= (skb_shinfo(skb)->nr_frags + 1)) {
hp               2307 drivers/net/ethernet/sun/sunhme.c 		spin_unlock_irq(&hp->happy_lock);
hp               2313 drivers/net/ethernet/sun/sunhme.c 	entry = hp->tx_new;
hp               2315 drivers/net/ethernet/sun/sunhme.c 	hp->tx_skbs[entry] = skb;
hp               2321 drivers/net/ethernet/sun/sunhme.c 		mapping = dma_map_single(hp->dma_dev, skb->data, len, DMA_TO_DEVICE);
hp               2322 drivers/net/ethernet/sun/sunhme.c 		if (unlikely(dma_mapping_error(hp->dma_dev, mapping)))
hp               2325 drivers/net/ethernet/sun/sunhme.c 		hme_write_txd(hp, &hp->happy_block->happy_meal_txd[entry],
hp               2337 drivers/net/ethernet/sun/sunhme.c 		first_mapping = dma_map_single(hp->dma_dev, skb->data, first_len,
hp               2339 drivers/net/ethernet/sun/sunhme.c 		if (unlikely(dma_mapping_error(hp->dma_dev, first_mapping)))
hp               2348 drivers/net/ethernet/sun/sunhme.c 			mapping = skb_frag_dma_map(hp->dma_dev, this_frag,
hp               2350 drivers/net/ethernet/sun/sunhme.c 			if (unlikely(dma_mapping_error(hp->dma_dev, mapping))) {
hp               2351 drivers/net/ethernet/sun/sunhme.c 				unmap_partial_tx_skb(hp, first_mapping, first_len,
hp               2358 drivers/net/ethernet/sun/sunhme.c 			hme_write_txd(hp, &hp->happy_block->happy_meal_txd[entry],
hp               2363 drivers/net/ethernet/sun/sunhme.c 		hme_write_txd(hp, &hp->happy_block->happy_meal_txd[first_entry],
hp               2368 drivers/net/ethernet/sun/sunhme.c 	hp->tx_new = entry;
hp               2370 drivers/net/ethernet/sun/sunhme.c 	if (TX_BUFFS_AVAIL(hp) <= (MAX_SKB_FRAGS + 1))
hp               2374 drivers/net/ethernet/sun/sunhme.c 	hme_write32(hp, hp->etxregs + ETX_PENDING, ETX_TP_DMAWAKEUP);
hp               2376 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2378 drivers/net/ethernet/sun/sunhme.c 	tx_add_log(hp, TXLOG_ACTION_TXMIT, 0);
hp               2382 drivers/net/ethernet/sun/sunhme.c 	hp->tx_skbs[hp->tx_new] = NULL;
hp               2383 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2392 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2394 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2395 drivers/net/ethernet/sun/sunhme.c 	happy_meal_get_counters(hp, hp->bigmacregs);
hp               2396 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2403 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2404 drivers/net/ethernet/sun/sunhme.c 	void __iomem *bregs = hp->bigmacregs;
hp               2408 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2411 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE0, 0xffff);
hp               2412 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE1, 0xffff);
hp               2413 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE2, 0xffff);
hp               2414 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE3, 0xffff);
hp               2416 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_RXCFG,
hp               2417 drivers/net/ethernet/sun/sunhme.c 			    hme_read32(hp, bregs + BMAC_RXCFG) | BIGMAC_RXCFG_PMISC);
hp               2427 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE0, hash_table[0]);
hp               2428 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE1, hash_table[1]);
hp               2429 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE2, hash_table[2]);
hp               2430 drivers/net/ethernet/sun/sunhme.c 		hme_write32(hp, bregs + BMAC_HTABLE3, hash_table[3]);
hp               2433 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2440 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2454 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2455 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmcr = happy_meal_tcvr_read(hp, hp->tcvregs, MII_BMCR);
hp               2456 drivers/net/ethernet/sun/sunhme.c 	hp->sw_lpa = happy_meal_tcvr_read(hp, hp->tcvregs, MII_LPA);
hp               2457 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2459 drivers/net/ethernet/sun/sunhme.c 	if (hp->sw_bmcr & BMCR_ANENABLE) {
hp               2461 drivers/net/ethernet/sun/sunhme.c 		speed = ((hp->sw_lpa & (LPA_100HALF | LPA_100FULL)) ?
hp               2465 drivers/net/ethernet/sun/sunhme.c 				(hp->sw_lpa & (LPA_100FULL)) ?
hp               2469 drivers/net/ethernet/sun/sunhme.c 				(hp->sw_lpa & (LPA_10FULL)) ?
hp               2473 drivers/net/ethernet/sun/sunhme.c 		speed = (hp->sw_bmcr & BMCR_SPEED100) ? SPEED_100 : SPEED_10;
hp               2475 drivers/net/ethernet/sun/sunhme.c 			(hp->sw_bmcr & BMCR_FULLDPLX) ?
hp               2488 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2502 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2503 drivers/net/ethernet/sun/sunhme.c 	del_timer(&hp->happy_timer);
hp               2504 drivers/net/ethernet/sun/sunhme.c 	happy_meal_begin_auto_negotiation(hp, hp->tcvregs, cmd);
hp               2505 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2512 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2516 drivers/net/ethernet/sun/sunhme.c 	if (hp->happy_flags & HFLAG_PCI) {
hp               2517 drivers/net/ethernet/sun/sunhme.c 		struct pci_dev *pdev = hp->happy_dev;
hp               2523 drivers/net/ethernet/sun/sunhme.c 		struct platform_device *op = hp->happy_dev;
hp               2535 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = netdev_priv(dev);
hp               2537 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2538 drivers/net/ethernet/sun/sunhme.c 	hp->sw_bmcr = happy_meal_tcvr_read(hp, hp->tcvregs, MII_BMCR);
hp               2539 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2541 drivers/net/ethernet/sun/sunhme.c 	return hp->sw_bmsr & BMSR_LSTATUS;
hp               2686 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp;
hp               2740 drivers/net/ethernet/sun/sunhme.c 	hp = netdev_priv(dev);
hp               2742 drivers/net/ethernet/sun/sunhme.c 	hp->happy_dev = op;
hp               2743 drivers/net/ethernet/sun/sunhme.c 	hp->dma_dev = &op->dev;
hp               2745 drivers/net/ethernet/sun/sunhme.c 	spin_lock_init(&hp->happy_lock);
hp               2749 drivers/net/ethernet/sun/sunhme.c 		hp->qfe_parent = qp;
hp               2750 drivers/net/ethernet/sun/sunhme.c 		hp->qfe_ent = qfe_slot;
hp               2754 drivers/net/ethernet/sun/sunhme.c 	hp->gregs = of_ioremap(&op->resource[0], 0,
hp               2756 drivers/net/ethernet/sun/sunhme.c 	if (!hp->gregs) {
hp               2761 drivers/net/ethernet/sun/sunhme.c 	hp->etxregs = of_ioremap(&op->resource[1], 0,
hp               2763 drivers/net/ethernet/sun/sunhme.c 	if (!hp->etxregs) {
hp               2768 drivers/net/ethernet/sun/sunhme.c 	hp->erxregs = of_ioremap(&op->resource[2], 0,
hp               2770 drivers/net/ethernet/sun/sunhme.c 	if (!hp->erxregs) {
hp               2775 drivers/net/ethernet/sun/sunhme.c 	hp->bigmacregs = of_ioremap(&op->resource[3], 0,
hp               2777 drivers/net/ethernet/sun/sunhme.c 	if (!hp->bigmacregs) {
hp               2782 drivers/net/ethernet/sun/sunhme.c 	hp->tcvregs = of_ioremap(&op->resource[4], 0,
hp               2784 drivers/net/ethernet/sun/sunhme.c 	if (!hp->tcvregs) {
hp               2789 drivers/net/ethernet/sun/sunhme.c 	hp->hm_revision = of_getintprop_default(dp, "hm-rev", 0xff);
hp               2790 drivers/net/ethernet/sun/sunhme.c 	if (hp->hm_revision == 0xff)
hp               2791 drivers/net/ethernet/sun/sunhme.c 		hp->hm_revision = 0xa0;
hp               2794 drivers/net/ethernet/sun/sunhme.c 	if (hp->hm_revision == 0x20 || hp->hm_revision == 0x21)
hp               2795 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags = HFLAG_20_21;
hp               2796 drivers/net/ethernet/sun/sunhme.c 	else if (hp->hm_revision != 0xa0)
hp               2797 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags = HFLAG_NOT_A0;
hp               2800 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags |= HFLAG_QUATTRO;
hp               2803 drivers/net/ethernet/sun/sunhme.c 	hp->happy_bursts = of_getintprop_default(sbus_dp,
hp               2806 drivers/net/ethernet/sun/sunhme.c 	hp->happy_block = dma_alloc_coherent(hp->dma_dev,
hp               2808 drivers/net/ethernet/sun/sunhme.c 					     &hp->hblock_dvma,
hp               2811 drivers/net/ethernet/sun/sunhme.c 	if (!hp->happy_block)
hp               2815 drivers/net/ethernet/sun/sunhme.c 	hp->linkcheck = 0;
hp               2818 drivers/net/ethernet/sun/sunhme.c 	hp->timer_state = asleep;
hp               2819 drivers/net/ethernet/sun/sunhme.c 	hp->timer_ticks = 0;
hp               2821 drivers/net/ethernet/sun/sunhme.c 	timer_setup(&hp->happy_timer, happy_meal_timer, 0);
hp               2823 drivers/net/ethernet/sun/sunhme.c 	hp->dev = dev;
hp               2832 drivers/net/ethernet/sun/sunhme.c 	hp->irq = op->archdata.irqs[0];
hp               2836 drivers/net/ethernet/sun/sunhme.c 	hp->read_desc32 = sbus_hme_read_desc32;
hp               2837 drivers/net/ethernet/sun/sunhme.c 	hp->write_txd = sbus_hme_write_txd;
hp               2838 drivers/net/ethernet/sun/sunhme.c 	hp->write_rxd = sbus_hme_write_rxd;
hp               2839 drivers/net/ethernet/sun/sunhme.c 	hp->read32 = sbus_hme_read32;
hp               2840 drivers/net/ethernet/sun/sunhme.c 	hp->write32 = sbus_hme_write32;
hp               2846 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               2847 drivers/net/ethernet/sun/sunhme.c 	happy_meal_set_initial_advertisement(hp);
hp               2848 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               2850 drivers/net/ethernet/sun/sunhme.c 	err = register_netdev(hp->dev);
hp               2857 drivers/net/ethernet/sun/sunhme.c 	platform_set_drvdata(op, hp);
hp               2871 drivers/net/ethernet/sun/sunhme.c 	dma_free_coherent(hp->dma_dev,
hp               2873 drivers/net/ethernet/sun/sunhme.c 			  hp->happy_block,
hp               2874 drivers/net/ethernet/sun/sunhme.c 			  hp->hblock_dvma);
hp               2877 drivers/net/ethernet/sun/sunhme.c 	if (hp->gregs)
hp               2878 drivers/net/ethernet/sun/sunhme.c 		of_iounmap(&op->resource[0], hp->gregs, GREG_REG_SIZE);
hp               2879 drivers/net/ethernet/sun/sunhme.c 	if (hp->etxregs)
hp               2880 drivers/net/ethernet/sun/sunhme.c 		of_iounmap(&op->resource[1], hp->etxregs, ETX_REG_SIZE);
hp               2881 drivers/net/ethernet/sun/sunhme.c 	if (hp->erxregs)
hp               2882 drivers/net/ethernet/sun/sunhme.c 		of_iounmap(&op->resource[2], hp->erxregs, ERX_REG_SIZE);
hp               2883 drivers/net/ethernet/sun/sunhme.c 	if (hp->bigmacregs)
hp               2884 drivers/net/ethernet/sun/sunhme.c 		of_iounmap(&op->resource[3], hp->bigmacregs, BMAC_REG_SIZE);
hp               2885 drivers/net/ethernet/sun/sunhme.c 	if (hp->tcvregs)
hp               2886 drivers/net/ethernet/sun/sunhme.c 		of_iounmap(&op->resource[4], hp->tcvregs, TCVR_REG_SIZE);
hp               2991 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp;
hp               3036 drivers/net/ethernet/sun/sunhme.c 	hp = netdev_priv(dev);
hp               3038 drivers/net/ethernet/sun/sunhme.c 	hp->happy_dev = pdev;
hp               3039 drivers/net/ethernet/sun/sunhme.c 	hp->dma_dev = &pdev->dev;
hp               3041 drivers/net/ethernet/sun/sunhme.c 	spin_lock_init(&hp->happy_lock);
hp               3044 drivers/net/ethernet/sun/sunhme.c 		hp->qfe_parent = qp;
hp               3045 drivers/net/ethernet/sun/sunhme.c 		hp->qfe_ent = qfe_slot;
hp               3093 drivers/net/ethernet/sun/sunhme.c 	hp->gregs      = (hpreg_base + 0x0000UL);
hp               3094 drivers/net/ethernet/sun/sunhme.c 	hp->etxregs    = (hpreg_base + 0x2000UL);
hp               3095 drivers/net/ethernet/sun/sunhme.c 	hp->erxregs    = (hpreg_base + 0x4000UL);
hp               3096 drivers/net/ethernet/sun/sunhme.c 	hp->bigmacregs = (hpreg_base + 0x6000UL);
hp               3097 drivers/net/ethernet/sun/sunhme.c 	hp->tcvregs    = (hpreg_base + 0x7000UL);
hp               3100 drivers/net/ethernet/sun/sunhme.c 	hp->hm_revision = of_getintprop_default(dp, "hm-rev", 0xff);
hp               3101 drivers/net/ethernet/sun/sunhme.c 	if (hp->hm_revision == 0xff)
hp               3102 drivers/net/ethernet/sun/sunhme.c 		hp->hm_revision = 0xc0 | (pdev->revision & 0x0f);
hp               3105 drivers/net/ethernet/sun/sunhme.c 	hp->hm_revision = 0x20;
hp               3109 drivers/net/ethernet/sun/sunhme.c 	if (hp->hm_revision == 0x20 || hp->hm_revision == 0x21)
hp               3110 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags = HFLAG_20_21;
hp               3111 drivers/net/ethernet/sun/sunhme.c 	else if (hp->hm_revision != 0xa0 && hp->hm_revision != 0xc0)
hp               3112 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags = HFLAG_NOT_A0;
hp               3115 drivers/net/ethernet/sun/sunhme.c 		hp->happy_flags |= HFLAG_QUATTRO;
hp               3118 drivers/net/ethernet/sun/sunhme.c 	hp->happy_flags |= HFLAG_PCI;
hp               3122 drivers/net/ethernet/sun/sunhme.c 	hp->happy_bursts = DMA_BURSTBITS;
hp               3125 drivers/net/ethernet/sun/sunhme.c 	hp->happy_block = dma_alloc_coherent(&pdev->dev, PAGE_SIZE,
hp               3126 drivers/net/ethernet/sun/sunhme.c 					     &hp->hblock_dvma, GFP_KERNEL);
hp               3128 drivers/net/ethernet/sun/sunhme.c 	if (!hp->happy_block)
hp               3131 drivers/net/ethernet/sun/sunhme.c 	hp->linkcheck = 0;
hp               3132 drivers/net/ethernet/sun/sunhme.c 	hp->timer_state = asleep;
hp               3133 drivers/net/ethernet/sun/sunhme.c 	hp->timer_ticks = 0;
hp               3135 drivers/net/ethernet/sun/sunhme.c 	timer_setup(&hp->happy_timer, happy_meal_timer, 0);
hp               3137 drivers/net/ethernet/sun/sunhme.c 	hp->irq = pdev->irq;
hp               3138 drivers/net/ethernet/sun/sunhme.c 	hp->dev = dev;
hp               3149 drivers/net/ethernet/sun/sunhme.c 	hp->read_desc32 = pci_hme_read_desc32;
hp               3150 drivers/net/ethernet/sun/sunhme.c 	hp->write_txd = pci_hme_write_txd;
hp               3151 drivers/net/ethernet/sun/sunhme.c 	hp->write_rxd = pci_hme_write_rxd;
hp               3152 drivers/net/ethernet/sun/sunhme.c 	hp->read32 = pci_hme_read32;
hp               3153 drivers/net/ethernet/sun/sunhme.c 	hp->write32 = pci_hme_write32;
hp               3159 drivers/net/ethernet/sun/sunhme.c 	spin_lock_irq(&hp->happy_lock);
hp               3160 drivers/net/ethernet/sun/sunhme.c 	happy_meal_set_initial_advertisement(hp);
hp               3161 drivers/net/ethernet/sun/sunhme.c 	spin_unlock_irq(&hp->happy_lock);
hp               3163 drivers/net/ethernet/sun/sunhme.c 	err = register_netdev(hp->dev);
hp               3170 drivers/net/ethernet/sun/sunhme.c 	pci_set_drvdata(pdev, hp);
hp               3201 drivers/net/ethernet/sun/sunhme.c 	iounmap(hp->gregs);
hp               3218 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = pci_get_drvdata(pdev);
hp               3219 drivers/net/ethernet/sun/sunhme.c 	struct net_device *net_dev = hp->dev;
hp               3223 drivers/net/ethernet/sun/sunhme.c 	dma_free_coherent(hp->dma_dev, PAGE_SIZE,
hp               3224 drivers/net/ethernet/sun/sunhme.c 			  hp->happy_block, hp->hblock_dvma);
hp               3225 drivers/net/ethernet/sun/sunhme.c 	iounmap(hp->gregs);
hp               3226 drivers/net/ethernet/sun/sunhme.c 	pci_release_regions(hp->happy_dev);
hp               3288 drivers/net/ethernet/sun/sunhme.c 	struct happy_meal *hp = platform_get_drvdata(op);
hp               3289 drivers/net/ethernet/sun/sunhme.c 	struct net_device *net_dev = hp->dev;
hp               3295 drivers/net/ethernet/sun/sunhme.c 	of_iounmap(&op->resource[0], hp->gregs, GREG_REG_SIZE);
hp               3296 drivers/net/ethernet/sun/sunhme.c 	of_iounmap(&op->resource[1], hp->etxregs, ETX_REG_SIZE);
hp               3297 drivers/net/ethernet/sun/sunhme.c 	of_iounmap(&op->resource[2], hp->erxregs, ERX_REG_SIZE);
hp               3298 drivers/net/ethernet/sun/sunhme.c 	of_iounmap(&op->resource[3], hp->bigmacregs, BMAC_REG_SIZE);
hp               3299 drivers/net/ethernet/sun/sunhme.c 	of_iounmap(&op->resource[4], hp->tcvregs, TCVR_REG_SIZE);
hp               3300 drivers/net/ethernet/sun/sunhme.c 	dma_free_coherent(hp->dma_dev,
hp               3302 drivers/net/ethernet/sun/sunhme.c 			  hp->happy_block,
hp               3303 drivers/net/ethernet/sun/sunhme.c 			  hp->hblock_dvma);
hp                365 drivers/net/ethernet/sun/sunhme.h #define TX_BUFFS_AVAIL(hp)                                    \
hp                366 drivers/net/ethernet/sun/sunhme.h         (((hp)->tx_old <= (hp)->tx_new) ?                     \
hp                367 drivers/net/ethernet/sun/sunhme.h 	  (hp)->tx_old + (TX_RING_SIZE - 1) - (hp)->tx_new :  \
hp                368 drivers/net/ethernet/sun/sunhme.h 			    (hp)->tx_old - (hp)->tx_new - 1)
hp                208 drivers/net/ethernet/sun/sunvnet.c 	struct hlist_head *hp = &vp->port_hash[hash];
hp                211 drivers/net/ethernet/sun/sunvnet.c 	hlist_for_each_entry_rcu(port, hp, hash) {
hp                383 drivers/net/ethernet/sun/sunvnet.c static struct vnet *vnet_find_parent(struct mdesc_handle *hp,
hp                390 drivers/net/ethernet/sun/sunvnet.c 	mdesc_for_each_arc(a, hp, port_node, MDESC_ARC_TYPE_BACK) {
hp                391 drivers/net/ethernet/sun/sunvnet.c 		u64 target = mdesc_arc_target(hp, a);
hp                394 drivers/net/ethernet/sun/sunvnet.c 		name = mdesc_get_property(hp, target, "name", NULL);
hp                398 drivers/net/ethernet/sun/sunvnet.c 		local_mac = mdesc_get_property(hp, target,
hp                425 drivers/net/ethernet/sun/sunvnet.c 	struct mdesc_handle *hp;
hp                432 drivers/net/ethernet/sun/sunvnet.c 	hp = mdesc_grab();
hp                434 drivers/net/ethernet/sun/sunvnet.c 	vp = vnet_find_parent(hp, vdev->mp, vdev);
hp                441 drivers/net/ethernet/sun/sunvnet.c 	rmac = mdesc_get_property(hp, vdev->mp, remote_macaddr_prop, &len);
hp                475 drivers/net/ethernet/sun/sunvnet.c 	if (mdesc_get_property(hp, vdev->mp, "switch-port", NULL))
hp                501 drivers/net/ethernet/sun/sunvnet.c 	mdesc_release(hp);
hp                509 drivers/net/ethernet/sun/sunvnet.c 	mdesc_release(hp);
hp                579 drivers/net/wireless/ath/ath9k/ath9k.h int ath_rx_tasklet(struct ath_softc *sc, int flush, bool hp);
hp               1059 drivers/net/wireless/ath/ath9k/recv.c int ath_rx_tasklet(struct ath_softc *sc, int flush, bool hp)
hp               1083 drivers/net/wireless/ath/ath9k/recv.c 	qtype = hp ? ATH9K_RX_QUEUE_HP : ATH9K_RX_QUEUE_LP;
hp                134 drivers/net/wireless/intel/iwlwifi/mvm/tx.c 			struct ipv6_opt_hdr *hp;
hp                144 drivers/net/wireless/intel/iwlwifi/mvm/tx.c 			hp = OPT_HDR(struct ipv6_opt_hdr, skb, off);
hp                145 drivers/net/wireless/intel/iwlwifi/mvm/tx.c 			protocol = hp->nexthdr;
hp                146 drivers/net/wireless/intel/iwlwifi/mvm/tx.c 			off += ipv6_optlen(hp);
hp                109 drivers/pci/hotplug/acpiphp.h 	struct acpi_hotplug_context hp;
hp                115 drivers/pci/hotplug/acpiphp.h static inline struct acpiphp_context *to_acpiphp_context(struct acpi_hotplug_context *hp)
hp                117 drivers/pci/hotplug/acpiphp.h 	return container_of(hp, struct acpiphp_context, hp);
hp                127 drivers/pci/hotplug/acpiphp.h 	return func_to_context(func)->hp.self;
hp                136 drivers/pci/hotplug/acpiphp.h 	struct acpi_hotplug_context hp;
hp                140 drivers/pci/hotplug/acpiphp.h static inline struct acpiphp_root_context *to_acpiphp_root_context(struct acpi_hotplug_context *hp)
hp                142 drivers/pci/hotplug/acpiphp.h 	return container_of(hp, struct acpiphp_root_context, hp);
hp                 68 drivers/pci/hotplug/acpiphp_glue.c 	context->hp.notify = acpiphp_hotplug_notify;
hp                 69 drivers/pci/hotplug/acpiphp_glue.c 	context->hp.fixup = acpiphp_post_dock_fixup;
hp                 70 drivers/pci/hotplug/acpiphp_glue.c 	acpi_set_hp_context(adev, &context->hp);
hp                 84 drivers/pci/hotplug/acpiphp_glue.c 	if (!adev->hp)
hp                 87 drivers/pci/hotplug/acpiphp_glue.c 	context = to_acpiphp_context(adev->hp);
hp                106 drivers/pci/hotplug/acpiphp_glue.c 	context->hp.self->hp = NULL;
hp                340 drivers/pci/hotplug/acpiphp_glue.c 			adev->hp->notify = NULL;
hp                341 drivers/pci/hotplug/acpiphp_glue.c 			adev->hp->fixup = NULL;
hp                754 drivers/pci/hotplug/acpiphp_glue.c 	if (adev->hp) {
hp                755 drivers/pci/hotplug/acpiphp_glue.c 		bridge = to_acpiphp_root_context(adev->hp)->root_bridge;
hp                774 drivers/pci/hotplug/acpiphp_glue.c 	acpi_handle handle = context->hp.self->handle;
hp                886 drivers/pci/hotplug/acpiphp_glue.c 		acpi_set_hp_context(adev, &root_context->hp);
hp                937 drivers/pci/hotplug/acpiphp_glue.c 		root_context = to_acpiphp_root_context(adev->hp);
hp                938 drivers/pci/hotplug/acpiphp_glue.c 		adev->hp = NULL;
hp                126 drivers/perf/fsl_imx8_ddr_perf.c 	IMX8_DDR_PMU_EVENT_ATTR(hp-read-credit-cnt, 0x11),
hp                131 drivers/perf/fsl_imx8_ddr_perf.c 	IMX8_DDR_PMU_EVENT_ATTR(hp-read, 0x23),
hp                132 drivers/perf/fsl_imx8_ddr_perf.c 	IMX8_DDR_PMU_EVENT_ATTR(hp-req-nocredit, 0x24),
hp                133 drivers/perf/fsl_imx8_ddr_perf.c 	IMX8_DDR_PMU_EVENT_ATTR(hp-xact-credit, 0x25),
hp                359 drivers/perf/xgene_pmu.c 	XGENE_PMU_EVENT_ATTR(mcu-hp-rd-request,			0x14),
hp                 47 drivers/platform/x86/surface3-wmi.c 	struct acpi_hotplug_context hp;
hp                221 drivers/platform/x86/surface3-wmi.c 	acpi_initialize_hp_context(s3_wmi.touchscreen_adev, &s3_wmi.hp,
hp                236 drivers/platform/x86/surface3-wmi.c 	s3_wmi.touchscreen_adev->hp = NULL;
hp                240 drivers/sbus/char/oradax.c 	struct mdesc_handle *hp = mdesc_grab();
hp                246 drivers/sbus/char/oradax.c 	if (hp == NULL) {
hp                251 drivers/sbus/char/oradax.c 	mdesc_for_each_node_by_name(hp, pn, "virtual-device") {
hp                252 drivers/sbus/char/oradax.c 		prop = (char *)mdesc_get_property(hp, pn, "name", &len);
hp                259 drivers/sbus/char/oradax.c 		prop = (char *)mdesc_get_property(hp, pn, "compatible", &len);
hp                356 drivers/sbus/char/oradax.c 	mdesc_release(hp);
hp                272 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 	struct fcoe_hdr		*hp;
hp                384 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 	hp = (struct fcoe_hdr *)(eh + 1);
hp                385 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 	memset(hp, 0, sizeof(*hp));
hp                387 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 		FC_FCOE_ENCAPS_VER(hp, FC_FCOE_VER);
hp                388 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 	hp->fcoe_sof = sof;
hp                520 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 	struct fcoe_hdr *hp;
hp                538 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 	hp = (struct fcoe_hdr *) skb_network_header(skb);
hp                546 drivers/scsi/bnx2fc/bnx2fc_fcoe.c 	fr_sof(fp) = hp->fcoe_sof;
hp               1487 drivers/scsi/fcoe/fcoe.c 	struct fcoe_hdr *hp;
hp               1574 drivers/scsi/fcoe/fcoe.c 	hp = (struct fcoe_hdr *)(eh + 1);
hp               1575 drivers/scsi/fcoe/fcoe.c 	memset(hp, 0, sizeof(*hp));
hp               1577 drivers/scsi/fcoe/fcoe.c 		FC_FCOE_ENCAPS_VER(hp, FC_FCOE_VER);
hp               1578 drivers/scsi/fcoe/fcoe.c 	hp->fcoe_sof = sof;
hp               1664 drivers/scsi/fcoe/fcoe.c 	struct fcoe_hdr *hp;
hp               1687 drivers/scsi/fcoe/fcoe.c 	hp = (struct fcoe_hdr *) skb_network_header(skb);
hp               1690 drivers/scsi/fcoe/fcoe.c 	if (unlikely(FC_FCOE_DECAPS_VER(hp) != FC_FCOE_VER)) {
hp               1696 drivers/scsi/fcoe/fcoe.c 			       "%x\n", FC_FCOE_DECAPS_VER(hp),
hp               1710 drivers/scsi/fcoe/fcoe.c 	fr_sof(fp) = hp->fcoe_sof;
hp                997 drivers/scsi/qedf/qedf_main.c 	struct fcoe_hdr		*hp;
hp               1143 drivers/scsi/qedf/qedf_main.c 	hp = (struct fcoe_hdr *)(eh + 1);
hp               1144 drivers/scsi/qedf/qedf_main.c 	memset(hp, 0, sizeof(*hp));
hp               1146 drivers/scsi/qedf/qedf_main.c 		FC_FCOE_ENCAPS_VER(hp, FC_FCOE_VER);
hp               1147 drivers/scsi/qedf/qedf_main.c 	hp->fcoe_sof = sof;
hp               2339 drivers/scsi/qedf/qedf_main.c 	struct fcoe_hdr *hp;
hp               2357 drivers/scsi/qedf/qedf_main.c 	hp = (struct fcoe_hdr *)skb->data;
hp               2365 drivers/scsi/qedf/qedf_main.c 	fr_sof(fp) = hp->fcoe_sof;
hp               4057 drivers/scsi/scsi_debug.c 	struct Scsi_Host *hp;
hp               4068 drivers/scsi/scsi_debug.c 	hp = sdp->host;
hp               4069 drivers/scsi/scsi_debug.c 	if (!hp)
hp               4071 drivers/scsi/scsi_debug.c 	sdbg_host = *(struct sdebug_host_info **)shost_priv(hp);
hp               4093 drivers/scsi/scsi_debug.c 	struct Scsi_Host *hp;
hp               4102 drivers/scsi/scsi_debug.c 	hp = sdp->host;
hp               4103 drivers/scsi/scsi_debug.c 	if (hp) {
hp               4104 drivers/scsi/scsi_debug.c 		sdbg_host = *(struct sdebug_host_info **)shost_priv(hp);
hp                415 drivers/scsi/sg.c 	sg_io_hdr_t *hp;
hp                489 drivers/scsi/sg.c 	hp = &srp->header;
hp                498 drivers/scsi/sg.c 	old_hdr->reply_len = (int) hp->timeout;
hp                500 drivers/scsi/sg.c 	old_hdr->pack_id = hp->pack_id;
hp                502 drivers/scsi/sg.c 	    ((srp->data.cmd_opcode >= 0xc0) && (12 == hp->cmd_len)) ? 1 : 0;
hp                503 drivers/scsi/sg.c 	old_hdr->target_status = hp->masked_status;
hp                504 drivers/scsi/sg.c 	old_hdr->host_status = hp->host_status;
hp                505 drivers/scsi/sg.c 	old_hdr->driver_status = hp->driver_status;
hp                506 drivers/scsi/sg.c 	if ((CHECK_CONDITION & hp->masked_status) ||
hp                507 drivers/scsi/sg.c 	    (DRIVER_SENSE & hp->driver_status))
hp                510 drivers/scsi/sg.c 	switch (hp->host_status) {
hp                532 drivers/scsi/sg.c 				  hp->masked_status == GOOD) ? 0 : EIO;
hp                567 drivers/scsi/sg.c 	sg_io_hdr_t *hp = &srp->header;
hp                575 drivers/scsi/sg.c 	hp->sb_len_wr = 0;
hp                576 drivers/scsi/sg.c 	if ((hp->mx_sb_len > 0) && hp->sbp) {
hp                577 drivers/scsi/sg.c 		if ((CHECK_CONDITION & hp->masked_status) ||
hp                578 drivers/scsi/sg.c 		    (DRIVER_SENSE & hp->driver_status)) {
hp                580 drivers/scsi/sg.c 			sb_len = (hp->mx_sb_len > sb_len) ? sb_len : hp->mx_sb_len;
hp                583 drivers/scsi/sg.c 			if (copy_to_user(hp->sbp, srp->sense_b, len)) {
hp                587 drivers/scsi/sg.c 			hp->sb_len_wr = len;
hp                590 drivers/scsi/sg.c 	if (hp->masked_status || hp->host_status || hp->driver_status)
hp                591 drivers/scsi/sg.c 		hp->info |= SG_INFO_CHECK;
hp                592 drivers/scsi/sg.c 	if (copy_to_user(buf, hp, SZ_SG_IO_HDR)) {
hp                612 drivers/scsi/sg.c 	sg_io_hdr_t *hp;
hp                671 drivers/scsi/sg.c 	hp = &srp->header;
hp                672 drivers/scsi/sg.c 	hp->interface_id = '\0';	/* indicator of old interface tunnelled */
hp                673 drivers/scsi/sg.c 	hp->cmd_len = (unsigned char) cmd_size;
hp                674 drivers/scsi/sg.c 	hp->iovec_count = 0;
hp                675 drivers/scsi/sg.c 	hp->mx_sb_len = 0;
hp                677 drivers/scsi/sg.c 		hp->dxfer_direction = (old_hdr.reply_len > SZ_SG_HEADER) ?
hp                680 drivers/scsi/sg.c 		hp->dxfer_direction = (mxsize > 0) ? SG_DXFER_FROM_DEV : SG_DXFER_NONE;
hp                681 drivers/scsi/sg.c 	hp->dxfer_len = mxsize;
hp                682 drivers/scsi/sg.c 	if ((hp->dxfer_direction == SG_DXFER_TO_DEV) ||
hp                683 drivers/scsi/sg.c 	    (hp->dxfer_direction == SG_DXFER_TO_FROM_DEV))
hp                684 drivers/scsi/sg.c 		hp->dxferp = (char __user *)buf + cmd_size;
hp                686 drivers/scsi/sg.c 		hp->dxferp = NULL;
hp                687 drivers/scsi/sg.c 	hp->sbp = NULL;
hp                688 drivers/scsi/sg.c 	hp->timeout = old_hdr.reply_len;	/* structure abuse ... */
hp                689 drivers/scsi/sg.c 	hp->flags = input_size;	/* structure abuse ... */
hp                690 drivers/scsi/sg.c 	hp->pack_id = old_hdr.pack_id;
hp                691 drivers/scsi/sg.c 	hp->usr_ptr = NULL;
hp                701 drivers/scsi/sg.c 	if (hp->dxfer_direction == SG_DXFER_TO_FROM_DEV) {
hp                722 drivers/scsi/sg.c 	sg_io_hdr_t *hp;
hp                739 drivers/scsi/sg.c 	hp = &srp->header;
hp                740 drivers/scsi/sg.c 	if (__copy_from_user(hp, buf, SZ_SG_IO_HDR)) {
hp                744 drivers/scsi/sg.c 	if (hp->interface_id != 'S') {
hp                748 drivers/scsi/sg.c 	if (hp->flags & SG_FLAG_MMAP_IO) {
hp                749 drivers/scsi/sg.c 		if (hp->dxfer_len > sfp->reserve.bufflen) {
hp                753 drivers/scsi/sg.c 		if (hp->flags & SG_FLAG_DIRECT_IO) {
hp                764 drivers/scsi/sg.c 	if ((!hp->cmdp) || (hp->cmd_len < 6) || (hp->cmd_len > sizeof (cmnd))) {
hp                768 drivers/scsi/sg.c 	if (!access_ok(hp->cmdp, hp->cmd_len)) {
hp                772 drivers/scsi/sg.c 	if (__copy_from_user(cmnd, hp->cmdp, hp->cmd_len)) {
hp                794 drivers/scsi/sg.c 	sg_io_hdr_t *hp = &srp->header;
hp                797 drivers/scsi/sg.c 	hp->status = 0;
hp                798 drivers/scsi/sg.c 	hp->masked_status = 0;
hp                799 drivers/scsi/sg.c 	hp->msg_status = 0;
hp                800 drivers/scsi/sg.c 	hp->info = 0;
hp                801 drivers/scsi/sg.c 	hp->host_status = 0;
hp                802 drivers/scsi/sg.c 	hp->driver_status = 0;
hp                803 drivers/scsi/sg.c 	hp->resid = 0;
hp                806 drivers/scsi/sg.c 			(int) cmnd[0], (int) hp->cmd_len));
hp                808 drivers/scsi/sg.c 	if (hp->dxfer_len >= SZ_256M) {
hp                833 drivers/scsi/sg.c 	hp->duration = jiffies_to_msecs(jiffies);
hp                834 drivers/scsi/sg.c 	if (hp->interface_id != '\0' &&	/* v3 (or later) interface */
hp                835 drivers/scsi/sg.c 	    (SG_FLAG_Q_AT_TAIL & hp->flags))
hp               1708 drivers/scsi/sg.c 	sg_io_hdr_t *hp = &srp->header;
hp               1709 drivers/scsi/sg.c 	int dxfer_len = (int) hp->dxfer_len;
hp               1710 drivers/scsi/sg.c 	int dxfer_dir = hp->dxfer_direction;
hp               1711 drivers/scsi/sg.c 	unsigned int iov_count = hp->iovec_count;
hp               1716 drivers/scsi/sg.c 	int rw = hp->dxfer_direction == SG_DXFER_TO_DEV ? WRITE : READ;
hp               1723 drivers/scsi/sg.c 	if (hp->cmd_len > BLK_MAX_CDB) {
hp               1724 drivers/scsi/sg.c 		long_cmdp = kzalloc(hp->cmd_len, GFP_KERNEL);
hp               1740 drivers/scsi/sg.c 	rq = blk_get_request(q, hp->dxfer_direction == SG_DXFER_TO_DEV ?
hp               1748 drivers/scsi/sg.c 	if (hp->cmd_len > BLK_MAX_CDB)
hp               1750 drivers/scsi/sg.c 	memcpy(req->cmd, cmd, hp->cmd_len);
hp               1751 drivers/scsi/sg.c 	req->cmd_len = hp->cmd_len;
hp               1760 drivers/scsi/sg.c 	if (sg_allow_dio && hp->flags & SG_FLAG_DIRECT_IO &&
hp               1763 drivers/scsi/sg.c 	    blk_rq_aligned(q, (unsigned long)hp->dxferp, dxfer_len))
hp               1774 drivers/scsi/sg.c 		} else if (hp->flags & SG_FLAG_MMAP_IO) {
hp               1793 drivers/scsi/sg.c 		md->null_mapped = hp->dxferp ? 0 : 1;
hp               1804 drivers/scsi/sg.c 		res = import_iovec(rw, hp->dxferp, iov_count, 0, &iov, &i);
hp               1808 drivers/scsi/sg.c 		iov_iter_truncate(&i, hp->dxfer_len);
hp               1817 drivers/scsi/sg.c 		res = blk_rq_map_user(q, rq, md, hp->dxferp,
hp               1818 drivers/scsi/sg.c 				      hp->dxfer_len, GFP_ATOMIC);
hp               1825 drivers/scsi/sg.c 			hp->info |= SG_INFO_DIRECT_IO;
hp               2522 drivers/scsi/sg.c 	const sg_io_hdr_t *hp;
hp               2540 drivers/scsi/sg.c 			hp = &srp->header;
hp               2541 drivers/scsi/sg.c 			new_interface = (hp->interface_id == '\0') ? 0 : 1;
hp               2544 drivers/scsi/sg.c 				    (SG_FLAG_MMAP_IO & hp->flags))
hp               2549 drivers/scsi/sg.c 				if (SG_INFO_DIRECT_IO_MASK & hp->info)
hp               2563 drivers/scsi/sg.c 				seq_printf(s, " dur=%d", hp->duration);
hp               2567 drivers/scsi/sg.c 					(new_interface ? hp->timeout :
hp               2569 drivers/scsi/sg.c 					(ms > hp->duration ? ms - hp->duration : 0));
hp                117 drivers/sh/intc/chip.c static struct intc_handle_int *intc_find_irq(struct intc_handle_int *hp,
hp                126 drivers/sh/intc/chip.c 	return bsearch(&key, hp, nr_hp, sizeof(*hp), intc_handle_int_cmp);
hp                 78 drivers/sh/intc/core.c 	struct intc_handle_int *hp;
hp                132 drivers/sh/intc/core.c 		hp = d->prio + d->nr_prio;
hp                133 drivers/sh/intc/core.c 		hp->irq = irq;
hp                134 drivers/sh/intc/core.c 		hp->handle = data[1];
hp                141 drivers/sh/intc/core.c 			hp->handle &= ~_INTC_MK(0x0f, 0, 0, 0, 0, 0);
hp                142 drivers/sh/intc/core.c 			hp->handle |= _INTC_MK(REG_FN_ERR, 0, 0, 0, 0, 0);
hp                157 drivers/spi/spi-bcm-qspi.c 	unsigned int hp;
hp                342 drivers/spi/spi-bcm-qspi.c 				       const struct spi_mem_op *op, int hp)
hp                351 drivers/spi/spi-bcm-qspi.c 		width, addrlen, hp);
hp                366 drivers/spi/spi-bcm-qspi.c 		if (hp) {
hp                373 drivers/spi/spi-bcm-qspi.c 		if (hp) {
hp                388 drivers/spi/spi-bcm-qspi.c 				      const struct spi_mem_op *op, int hp)
hp                395 drivers/spi/spi-bcm-qspi.c 		width, addrlen, hp);
hp                433 drivers/spi/spi-bcm-qspi.c 				  const struct spi_mem_op *op, int hp)
hp                450 drivers/spi/spi-bcm-qspi.c 			error = bcm_qspi_bspi_set_override(qspi, op, hp);
hp                455 drivers/spi/spi-bcm-qspi.c 		error = bcm_qspi_bspi_set_flex_mode(qspi, op, hp);
hp                460 drivers/spi/spi-bcm-qspi.c 			 width, addrlen, hp);
hp                463 drivers/spi/spi-bcm-qspi.c 		   qspi->xfer_mode.hp != hp) {
hp                466 drivers/spi/spi-bcm-qspi.c 		qspi->xfer_mode.hp = hp;
hp                472 drivers/spi/spi-bcm-qspi.c 			qspi->xfer_mode.hp != -1 ? ", hp mode" : "");
hp               1358 drivers/spi/spi-bcm-qspi.c 	qspi->xfer_mode.hp = -1;
hp                 21 drivers/staging/exfat/exfat_cache.c 	struct buf_cache_t *bp, *hp;
hp                 27 drivers/staging/exfat/exfat_cache.c 	hp = &p_fs->FAT_cache_hash_list[off];
hp                 28 drivers/staging/exfat/exfat_cache.c 	for (bp = hp->hash_next; bp != hp; bp = bp->hash_next) {
hp                 85 drivers/staging/exfat/exfat_cache.c 	struct buf_cache_t *hp;
hp                 93 drivers/staging/exfat/exfat_cache.c 	hp = &p_fs->FAT_cache_hash_list[off];
hp                 94 drivers/staging/exfat/exfat_cache.c 	bp->hash_next = hp->hash_next;
hp                 95 drivers/staging/exfat/exfat_cache.c 	bp->hash_prev = hp;
hp                 96 drivers/staging/exfat/exfat_cache.c 	hp->hash_next->hash_prev = bp;
hp                 97 drivers/staging/exfat/exfat_cache.c 	hp->hash_next = bp;
hp                110 drivers/staging/exfat/exfat_cache.c 	struct buf_cache_t *hp;
hp                118 drivers/staging/exfat/exfat_cache.c 	hp = &p_fs->buf_cache_hash_list[off];
hp                119 drivers/staging/exfat/exfat_cache.c 	bp->hash_next = hp->hash_next;
hp                120 drivers/staging/exfat/exfat_cache.c 	bp->hash_prev = hp;
hp                121 drivers/staging/exfat/exfat_cache.c 	hp->hash_next->hash_prev = bp;
hp                122 drivers/staging/exfat/exfat_cache.c 	hp->hash_next = bp;
hp                535 drivers/staging/exfat/exfat_cache.c 	struct buf_cache_t *bp, *hp;
hp                541 drivers/staging/exfat/exfat_cache.c 	hp = &p_fs->buf_cache_hash_list[off];
hp                542 drivers/staging/exfat/exfat_cache.c 	for (bp = hp->hash_next; bp != hp; bp = bp->hash_next) {
hp                 92 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp;
hp                 97 drivers/tty/hvc/hvc_console.c 	list_for_each_entry(hp, &hvc_structs, next) {
hp                 98 drivers/tty/hvc/hvc_console.c 		spin_lock_irqsave(&hp->lock, flags);
hp                 99 drivers/tty/hvc/hvc_console.c 		if (hp->index == index) {
hp                100 drivers/tty/hvc/hvc_console.c 			tty_port_get(&hp->port);
hp                101 drivers/tty/hvc/hvc_console.c 			spin_unlock_irqrestore(&hp->lock, flags);
hp                103 drivers/tty/hvc/hvc_console.c 			return hp;
hp                105 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->lock, flags);
hp                107 drivers/tty/hvc/hvc_console.c 	hp = NULL;
hp                110 drivers/tty/hvc/hvc_console.c 	return hp;
hp                131 drivers/tty/hvc/hvc_console.c static int hvc_flush(struct hvc_struct *hp)
hp                133 drivers/tty/hvc/hvc_console.c 	return __hvc_flush(hp->ops, hp->vtermno, true);
hp                251 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = container_of(port, struct hvc_struct, port);
hp                256 drivers/tty/hvc/hvc_console.c 	spin_lock_irqsave(&hp->lock, flags);
hp                257 drivers/tty/hvc/hvc_console.c 	list_del(&(hp->next));
hp                258 drivers/tty/hvc/hvc_console.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                262 drivers/tty/hvc/hvc_console.c 	kfree(hp);
hp                287 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp;
hp                296 drivers/tty/hvc/hvc_console.c 	hp = hvc_get_by_index(index);
hp                297 drivers/tty/hvc/hvc_console.c 	if (hp) {
hp                298 drivers/tty/hvc/hvc_console.c 		tty_port_put(&hp->port);
hp                327 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp;
hp                331 drivers/tty/hvc/hvc_console.c 	hp = hvc_get_by_index(tty->index);
hp                332 drivers/tty/hvc/hvc_console.c 	if (!hp)
hp                335 drivers/tty/hvc/hvc_console.c 	tty->driver_data = hp;
hp                337 drivers/tty/hvc/hvc_console.c 	rc = tty_port_install(&hp->port, driver, tty);
hp                339 drivers/tty/hvc/hvc_console.c 		tty_port_put(&hp->port);
hp                349 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                353 drivers/tty/hvc/hvc_console.c 	spin_lock_irqsave(&hp->port.lock, flags);
hp                355 drivers/tty/hvc/hvc_console.c 	if (hp->port.count++ > 0) {
hp                356 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->port.lock, flags);
hp                360 drivers/tty/hvc/hvc_console.c 	spin_unlock_irqrestore(&hp->port.lock, flags);
hp                362 drivers/tty/hvc/hvc_console.c 	tty_port_tty_set(&hp->port, tty);
hp                364 drivers/tty/hvc/hvc_console.c 	if (hp->ops->notifier_add)
hp                365 drivers/tty/hvc/hvc_console.c 		rc = hp->ops->notifier_add(hp, hp->data);
hp                378 drivers/tty/hvc/hvc_console.c 			if (hp->ops->dtr_rts)
hp                379 drivers/tty/hvc/hvc_console.c 				hp->ops->dtr_rts(hp, 1);
hp                380 drivers/tty/hvc/hvc_console.c 		tty_port_set_initialized(&hp->port, true);
hp                391 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                397 drivers/tty/hvc/hvc_console.c 	spin_lock_irqsave(&hp->port.lock, flags);
hp                399 drivers/tty/hvc/hvc_console.c 	if (--hp->port.count == 0) {
hp                400 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->port.lock, flags);
hp                402 drivers/tty/hvc/hvc_console.c 		tty_port_tty_set(&hp->port, NULL);
hp                404 drivers/tty/hvc/hvc_console.c 		if (!tty_port_initialized(&hp->port))
hp                408 drivers/tty/hvc/hvc_console.c 			if (hp->ops->dtr_rts)
hp                409 drivers/tty/hvc/hvc_console.c 				hp->ops->dtr_rts(hp, 0);
hp                411 drivers/tty/hvc/hvc_console.c 		if (hp->ops->notifier_del)
hp                412 drivers/tty/hvc/hvc_console.c 			hp->ops->notifier_del(hp, hp->data);
hp                415 drivers/tty/hvc/hvc_console.c 		cancel_work_sync(&hp->tty_resize);
hp                423 drivers/tty/hvc/hvc_console.c 		tty_port_set_initialized(&hp->port, false);
hp                425 drivers/tty/hvc/hvc_console.c 		if (hp->port.count < 0)
hp                427 drivers/tty/hvc/hvc_console.c 				hp->vtermno, hp->port.count);
hp                428 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->port.lock, flags);
hp                434 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                436 drivers/tty/hvc/hvc_console.c 	tty_port_put(&hp->port);
hp                441 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                444 drivers/tty/hvc/hvc_console.c 	if (!hp)
hp                448 drivers/tty/hvc/hvc_console.c 	cancel_work_sync(&hp->tty_resize);
hp                450 drivers/tty/hvc/hvc_console.c 	spin_lock_irqsave(&hp->port.lock, flags);
hp                457 drivers/tty/hvc/hvc_console.c 	if (hp->port.count <= 0) {
hp                458 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->port.lock, flags);
hp                462 drivers/tty/hvc/hvc_console.c 	hp->port.count = 0;
hp                463 drivers/tty/hvc/hvc_console.c 	spin_unlock_irqrestore(&hp->port.lock, flags);
hp                464 drivers/tty/hvc/hvc_console.c 	tty_port_tty_set(&hp->port, NULL);
hp                466 drivers/tty/hvc/hvc_console.c 	hp->n_outbuf = 0;
hp                468 drivers/tty/hvc/hvc_console.c 	if (hp->ops->notifier_hangup)
hp                469 drivers/tty/hvc/hvc_console.c 		hp->ops->notifier_hangup(hp, hp->data);
hp                476 drivers/tty/hvc/hvc_console.c static int hvc_push(struct hvc_struct *hp)
hp                480 drivers/tty/hvc/hvc_console.c 	n = hp->ops->put_chars(hp->vtermno, hp->outbuf, hp->n_outbuf);
hp                483 drivers/tty/hvc/hvc_console.c 			hp->do_wakeup = 1;
hp                488 drivers/tty/hvc/hvc_console.c 		hp->n_outbuf = 0;
hp                490 drivers/tty/hvc/hvc_console.c 		hp->n_outbuf -= n;
hp                491 drivers/tty/hvc/hvc_console.c 	if (hp->n_outbuf > 0)
hp                492 drivers/tty/hvc/hvc_console.c 		memmove(hp->outbuf, hp->outbuf + n, hp->n_outbuf);
hp                494 drivers/tty/hvc/hvc_console.c 		hp->do_wakeup = 1;
hp                501 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                506 drivers/tty/hvc/hvc_console.c 	if (!hp)
hp                510 drivers/tty/hvc/hvc_console.c 	if (hp->port.count <= 0)
hp                516 drivers/tty/hvc/hvc_console.c 		spin_lock_irqsave(&hp->lock, flags);
hp                518 drivers/tty/hvc/hvc_console.c 		rsize = hp->outbuf_size - hp->n_outbuf;
hp                523 drivers/tty/hvc/hvc_console.c 			memcpy(hp->outbuf + hp->n_outbuf, buf, rsize);
hp                526 drivers/tty/hvc/hvc_console.c 			hp->n_outbuf += rsize;
hp                530 drivers/tty/hvc/hvc_console.c 		if (hp->n_outbuf > 0)
hp                531 drivers/tty/hvc/hvc_console.c 			ret = hvc_push(hp);
hp                533 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->lock, flags);
hp                539 drivers/tty/hvc/hvc_console.c 			if (hp->n_outbuf > 0)
hp                540 drivers/tty/hvc/hvc_console.c 				hvc_flush(hp);
hp                548 drivers/tty/hvc/hvc_console.c 	if (hp->n_outbuf)
hp                565 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp;
hp                570 drivers/tty/hvc/hvc_console.c 	hp = container_of(work, struct hvc_struct, tty_resize);
hp                572 drivers/tty/hvc/hvc_console.c 	tty = tty_port_tty_get(&hp->port);
hp                576 drivers/tty/hvc/hvc_console.c 	spin_lock_irqsave(&hp->lock, hvc_flags);
hp                577 drivers/tty/hvc/hvc_console.c 	ws = hp->ws;
hp                578 drivers/tty/hvc/hvc_console.c 	spin_unlock_irqrestore(&hp->lock, hvc_flags);
hp                591 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                593 drivers/tty/hvc/hvc_console.c 	if (!hp)
hp                596 drivers/tty/hvc/hvc_console.c 	return hp->outbuf_size - hp->n_outbuf;
hp                601 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                603 drivers/tty/hvc/hvc_console.c 	if (!hp)
hp                605 drivers/tty/hvc/hvc_console.c 	return hp->n_outbuf;
hp                632 drivers/tty/hvc/hvc_console.c static int __hvc_poll(struct hvc_struct *hp, bool may_sleep)
hp                641 drivers/tty/hvc/hvc_console.c 	spin_lock_irqsave(&hp->lock, flags);
hp                644 drivers/tty/hvc/hvc_console.c 	if (hp->n_outbuf > 0)
hp                645 drivers/tty/hvc/hvc_console.c 		written_total = hvc_push(hp);
hp                648 drivers/tty/hvc/hvc_console.c 	if (hp->n_outbuf > 0) {
hp                655 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->lock, flags);
hp                657 drivers/tty/hvc/hvc_console.c 		spin_lock_irqsave(&hp->lock, flags);
hp                661 drivers/tty/hvc/hvc_console.c 	tty = tty_port_tty_get(&hp->port);
hp                672 drivers/tty/hvc/hvc_console.c 	if (!hp->irq_requested)
hp                677 drivers/tty/hvc/hvc_console.c 	count = tty_buffer_request_room(&hp->port, N_INBUF);
hp                685 drivers/tty/hvc/hvc_console.c 	n = hp->ops->get_chars(hp->vtermno, buf, count);
hp                689 drivers/tty/hvc/hvc_console.c 			spin_unlock_irqrestore(&hp->lock, flags);
hp                691 drivers/tty/hvc/hvc_console.c 			spin_lock_irqsave(&hp->lock, flags);
hp                705 drivers/tty/hvc/hvc_console.c 		if (hp->index == hvc_console.index) {
hp                721 drivers/tty/hvc/hvc_console.c 		tty_insert_flip_char(&hp->port, buf[i], 0);
hp                727 drivers/tty/hvc/hvc_console.c 		spin_unlock_irqrestore(&hp->lock, flags);
hp                729 drivers/tty/hvc/hvc_console.c 		spin_lock_irqsave(&hp->lock, flags);
hp                743 drivers/tty/hvc/hvc_console.c 	if (hp->do_wakeup) {
hp                744 drivers/tty/hvc/hvc_console.c 		hp->do_wakeup = 0;
hp                748 drivers/tty/hvc/hvc_console.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                755 drivers/tty/hvc/hvc_console.c 		tty_flip_buffer_push(&hp->port);
hp                762 drivers/tty/hvc/hvc_console.c int hvc_poll(struct hvc_struct *hp)
hp                764 drivers/tty/hvc/hvc_console.c 	return __hvc_poll(hp, false);
hp                778 drivers/tty/hvc/hvc_console.c void __hvc_resize(struct hvc_struct *hp, struct winsize ws)
hp                780 drivers/tty/hvc/hvc_console.c 	hp->ws = ws;
hp                781 drivers/tty/hvc/hvc_console.c 	schedule_work(&hp->tty_resize);
hp                793 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp;
hp                803 drivers/tty/hvc/hvc_console.c 			list_for_each_entry(hp, &hvc_structs, next) {
hp                804 drivers/tty/hvc/hvc_console.c 				poll_mask |= __hvc_poll(hp, true);
hp                838 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                840 drivers/tty/hvc/hvc_console.c 	if (!hp || !hp->ops->tiocmget)
hp                842 drivers/tty/hvc/hvc_console.c 	return hp->ops->tiocmget(hp);
hp                848 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                850 drivers/tty/hvc/hvc_console.c 	if (!hp || !hp->ops->tiocmset)
hp                852 drivers/tty/hvc/hvc_console.c 	return hp->ops->tiocmset(hp, set, clear);
hp                864 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                868 drivers/tty/hvc/hvc_console.c 	n = hp->ops->get_chars(hp->vtermno, &ch, 1);
hp                879 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp = tty->driver_data;
hp                883 drivers/tty/hvc/hvc_console.c 		n = hp->ops->put_chars(hp->vtermno, &ch, 1);
hp                915 drivers/tty/hvc/hvc_console.c 	struct hvc_struct *hp;
hp                925 drivers/tty/hvc/hvc_console.c 	hp = kzalloc(ALIGN(sizeof(*hp), sizeof(long)) + outbuf_size,
hp                927 drivers/tty/hvc/hvc_console.c 	if (!hp)
hp                930 drivers/tty/hvc/hvc_console.c 	hp->vtermno = vtermno;
hp                931 drivers/tty/hvc/hvc_console.c 	hp->data = data;
hp                932 drivers/tty/hvc/hvc_console.c 	hp->ops = ops;
hp                933 drivers/tty/hvc/hvc_console.c 	hp->outbuf_size = outbuf_size;
hp                934 drivers/tty/hvc/hvc_console.c 	hp->outbuf = &((char *)hp)[ALIGN(sizeof(*hp), sizeof(long))];
hp                936 drivers/tty/hvc/hvc_console.c 	tty_port_init(&hp->port);
hp                937 drivers/tty/hvc/hvc_console.c 	hp->port.ops = &hvc_port_ops;
hp                939 drivers/tty/hvc/hvc_console.c 	INIT_WORK(&hp->tty_resize, hvc_set_winsz);
hp                940 drivers/tty/hvc/hvc_console.c 	spin_lock_init(&hp->lock);
hp                948 drivers/tty/hvc/hvc_console.c 		if (vtermnos[i] == hp->vtermno &&
hp                949 drivers/tty/hvc/hvc_console.c 		    cons_ops[i] == hp->ops)
hp                963 drivers/tty/hvc/hvc_console.c 	hp->index = i;
hp                969 drivers/tty/hvc/hvc_console.c 	list_add_tail(&(hp->next), &hvc_structs);
hp                975 drivers/tty/hvc/hvc_console.c 	return hp;
hp                979 drivers/tty/hvc/hvc_console.c int hvc_remove(struct hvc_struct *hp)
hp                984 drivers/tty/hvc/hvc_console.c 	tty = tty_port_tty_get(&hp->port);
hp                987 drivers/tty/hvc/hvc_console.c 	spin_lock_irqsave(&hp->lock, flags);
hp                988 drivers/tty/hvc/hvc_console.c 	if (hp->index < MAX_NR_HVC_CONSOLES) {
hp                989 drivers/tty/hvc/hvc_console.c 		vtermnos[hp->index] = -1;
hp                990 drivers/tty/hvc/hvc_console.c 		cons_ops[hp->index] = NULL;
hp                995 drivers/tty/hvc/hvc_console.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp               1004 drivers/tty/hvc/hvc_console.c 	tty_port_put(&hp->port);
hp                 60 drivers/tty/hvc/hvc_console.h 	int (*notifier_add)(struct hvc_struct *hp, int irq);
hp                 61 drivers/tty/hvc/hvc_console.h 	void (*notifier_del)(struct hvc_struct *hp, int irq);
hp                 62 drivers/tty/hvc/hvc_console.h 	void (*notifier_hangup)(struct hvc_struct *hp, int irq);
hp                 65 drivers/tty/hvc/hvc_console.h 	int (*tiocmget)(struct hvc_struct *hp);
hp                 66 drivers/tty/hvc/hvc_console.h 	int (*tiocmset)(struct hvc_struct *hp, unsigned int set, unsigned int clear);
hp                 69 drivers/tty/hvc/hvc_console.h 	void (*dtr_rts)(struct hvc_struct *hp, int raise);
hp                 80 drivers/tty/hvc/hvc_console.h extern int hvc_remove(struct hvc_struct *hp);
hp                 83 drivers/tty/hvc/hvc_console.h int hvc_poll(struct hvc_struct *hp);
hp                 87 drivers/tty/hvc/hvc_console.h extern void __hvc_resize(struct hvc_struct *hp, struct winsize ws);
hp                 89 drivers/tty/hvc/hvc_console.h static inline void hvc_resize(struct hvc_struct *hp, struct winsize ws)
hp                 93 drivers/tty/hvc/hvc_console.h 	spin_lock_irqsave(&hp->lock, flags);
hp                 94 drivers/tty/hvc/hvc_console.h 	__hvc_resize(hp, ws);
hp                 95 drivers/tty/hvc/hvc_console.h 	spin_unlock_irqrestore(&hp->lock, flags);
hp                 99 drivers/tty/hvc/hvc_console.h extern int notifier_add_irq(struct hvc_struct *hp, int data);
hp                100 drivers/tty/hvc/hvc_console.h extern void notifier_del_irq(struct hvc_struct *hp, int data);
hp                101 drivers/tty/hvc/hvc_console.h extern void notifier_hangup_irq(struct hvc_struct *hp, int data);
hp                 29 drivers/tty/hvc/hvc_irq.c int notifier_add_irq(struct hvc_struct *hp, int irq)
hp                 34 drivers/tty/hvc/hvc_irq.c 		hp->irq_requested = 0;
hp                 37 drivers/tty/hvc/hvc_irq.c 	rc = request_irq(irq, hvc_handle_interrupt, hp->flags,
hp                 38 drivers/tty/hvc/hvc_irq.c 			"hvc_console", hp);
hp                 40 drivers/tty/hvc/hvc_irq.c 		hp->irq_requested = 1;
hp                 44 drivers/tty/hvc/hvc_irq.c void notifier_del_irq(struct hvc_struct *hp, int irq)
hp                 46 drivers/tty/hvc/hvc_irq.c 	if (!hp->irq_requested)
hp                 48 drivers/tty/hvc/hvc_irq.c 	free_irq(irq, hp);
hp                 49 drivers/tty/hvc/hvc_irq.c 	hp->irq_requested = 0;
hp                 52 drivers/tty/hvc/hvc_irq.c void notifier_hangup_irq(struct hvc_struct *hp, int irq)
hp                 54 drivers/tty/hvc/hvc_irq.c 	notifier_del_irq(hp, irq);
hp                490 drivers/tty/hvc/hvc_iucv.c static int hvc_iucv_notifier_add(struct hvc_struct *hp, int id)
hp                636 drivers/tty/hvc/hvc_iucv.c static void hvc_iucv_notifier_hangup(struct hvc_struct *hp, int id)
hp                670 drivers/tty/hvc/hvc_iucv.c static void hvc_iucv_dtr_rts(struct hvc_struct *hp, int raise)
hp                681 drivers/tty/hvc/hvc_iucv.c 	priv = hvc_iucv_get_private(hp->vtermno);
hp                717 drivers/tty/hvc/hvc_iucv.c static void hvc_iucv_notifier_del(struct hvc_struct *hp, int id)
hp                 81 drivers/tty/hvc/hvc_opal.c static int hvc_opal_hvsi_open(struct hvc_struct *hp, int data)
hp                 83 drivers/tty/hvc/hvc_opal.c 	struct hvc_opal_priv *pv = hvc_opal_privs[hp->vtermno];
hp                 86 drivers/tty/hvc/hvc_opal.c 	pr_devel("HVSI@%x: do open !\n", hp->vtermno);
hp                 88 drivers/tty/hvc/hvc_opal.c 	rc = notifier_add_irq(hp, data);
hp                 92 drivers/tty/hvc/hvc_opal.c 	return hvsilib_open(&pv->hvsi, hp);
hp                 95 drivers/tty/hvc/hvc_opal.c static void hvc_opal_hvsi_close(struct hvc_struct *hp, int data)
hp                 97 drivers/tty/hvc/hvc_opal.c 	struct hvc_opal_priv *pv = hvc_opal_privs[hp->vtermno];
hp                 99 drivers/tty/hvc/hvc_opal.c 	pr_devel("HVSI@%x: do close !\n", hp->vtermno);
hp                101 drivers/tty/hvc/hvc_opal.c 	hvsilib_close(&pv->hvsi, hp);
hp                103 drivers/tty/hvc/hvc_opal.c 	notifier_del_irq(hp, data);
hp                106 drivers/tty/hvc/hvc_opal.c void hvc_opal_hvsi_hangup(struct hvc_struct *hp, int data)
hp                108 drivers/tty/hvc/hvc_opal.c 	struct hvc_opal_priv *pv = hvc_opal_privs[hp->vtermno];
hp                110 drivers/tty/hvc/hvc_opal.c 	pr_devel("HVSI@%x: do hangup !\n", hp->vtermno);
hp                112 drivers/tty/hvc/hvc_opal.c 	hvsilib_close(&pv->hvsi, hp);
hp                114 drivers/tty/hvc/hvc_opal.c 	notifier_hangup_irq(hp, data);
hp                117 drivers/tty/hvc/hvc_opal.c static int hvc_opal_hvsi_tiocmget(struct hvc_struct *hp)
hp                119 drivers/tty/hvc/hvc_opal.c 	struct hvc_opal_priv *pv = hvc_opal_privs[hp->vtermno];
hp                126 drivers/tty/hvc/hvc_opal.c static int hvc_opal_hvsi_tiocmset(struct hvc_struct *hp, unsigned int set,
hp                129 drivers/tty/hvc/hvc_opal.c 	struct hvc_opal_priv *pv = hvc_opal_privs[hp->vtermno];
hp                132 drivers/tty/hvc/hvc_opal.c 		 hp->vtermno, set, clear);
hp                156 drivers/tty/hvc/hvc_opal.c 	struct hvc_struct *hp;
hp                224 drivers/tty/hvc/hvc_opal.c 	hp = hvc_alloc(termno, irq, ops, MAX_VIO_PUT_CHARS);
hp                225 drivers/tty/hvc/hvc_opal.c 	if (IS_ERR(hp))
hp                226 drivers/tty/hvc/hvc_opal.c 		return PTR_ERR(hp);
hp                229 drivers/tty/hvc/hvc_opal.c 	hp->flags = IRQF_SHARED;
hp                230 drivers/tty/hvc/hvc_opal.c 	dev_set_drvdata(&dev->dev, hp);
hp                237 drivers/tty/hvc/hvc_opal.c 	struct hvc_struct *hp = dev_get_drvdata(&dev->dev);
hp                240 drivers/tty/hvc/hvc_opal.c 	termno = hp->vtermno;
hp                241 drivers/tty/hvc/hvc_opal.c 	rc = hvc_remove(hp);
hp                 68 drivers/tty/hvc/hvc_rtas.c 	struct hvc_struct *hp;
hp                 84 drivers/tty/hvc/hvc_rtas.c 	hp = hvc_alloc(hvc_rtas_cookie, 0, &hvc_rtas_get_put_ops, 16);
hp                 85 drivers/tty/hvc/hvc_rtas.c 	if (IS_ERR(hp))
hp                 86 drivers/tty/hvc/hvc_rtas.c 		return PTR_ERR(hp);
hp                 88 drivers/tty/hvc/hvc_rtas.c 	hvc_rtas_dev = hp;
hp                 55 drivers/tty/hvc/hvc_udbg.c 	struct hvc_struct *hp;
hp                 62 drivers/tty/hvc/hvc_udbg.c 	hp = hvc_alloc(0, 0, &hvc_udbg_ops, 16);
hp                 63 drivers/tty/hvc/hvc_udbg.c 	if (IS_ERR(hp))
hp                 64 drivers/tty/hvc/hvc_udbg.c 		return PTR_ERR(hp);
hp                 66 drivers/tty/hvc/hvc_udbg.c 	hvc_udbg_dev = hp;
hp                156 drivers/tty/hvc/hvc_vio.c static int hvterm_hvsi_open(struct hvc_struct *hp, int data)
hp                158 drivers/tty/hvc/hvc_vio.c 	struct hvterm_priv *pv = hvterm_privs[hp->vtermno];
hp                163 drivers/tty/hvc/hvc_vio.c 	rc = notifier_add_irq(hp, data);
hp                167 drivers/tty/hvc/hvc_vio.c 	return hvsilib_open(&pv->hvsi, hp);
hp                170 drivers/tty/hvc/hvc_vio.c static void hvterm_hvsi_close(struct hvc_struct *hp, int data)
hp                172 drivers/tty/hvc/hvc_vio.c 	struct hvterm_priv *pv = hvterm_privs[hp->vtermno];
hp                176 drivers/tty/hvc/hvc_vio.c 	hvsilib_close(&pv->hvsi, hp);
hp                178 drivers/tty/hvc/hvc_vio.c 	notifier_del_irq(hp, data);
hp                181 drivers/tty/hvc/hvc_vio.c void hvterm_hvsi_hangup(struct hvc_struct *hp, int data)
hp                183 drivers/tty/hvc/hvc_vio.c 	struct hvterm_priv *pv = hvterm_privs[hp->vtermno];
hp                187 drivers/tty/hvc/hvc_vio.c 	hvsilib_close(&pv->hvsi, hp);
hp                189 drivers/tty/hvc/hvc_vio.c 	notifier_hangup_irq(hp, data);
hp                192 drivers/tty/hvc/hvc_vio.c static int hvterm_hvsi_tiocmget(struct hvc_struct *hp)
hp                194 drivers/tty/hvc/hvc_vio.c 	struct hvterm_priv *pv = hvterm_privs[hp->vtermno];
hp                201 drivers/tty/hvc/hvc_vio.c static int hvterm_hvsi_tiocmset(struct hvc_struct *hp, unsigned int set,
hp                204 drivers/tty/hvc/hvc_vio.c 	struct hvterm_priv *pv = hvterm_privs[hp->vtermno];
hp                300 drivers/tty/hvc/hvc_vio.c 	struct hvc_struct *hp;
hp                350 drivers/tty/hvc/hvc_vio.c 	hp = hvc_alloc(termno, vdev->irq, ops, MAX_VIO_PUT_CHARS);
hp                351 drivers/tty/hvc/hvc_vio.c 	if (IS_ERR(hp))
hp                352 drivers/tty/hvc/hvc_vio.c 		return PTR_ERR(hp);
hp                353 drivers/tty/hvc/hvc_vio.c 	dev_set_drvdata(&vdev->dev, hp);
hp                356 drivers/tty/hvc/hvc_vio.c 	if (hp->index == 0 && !udbg_putc) {
hp                 87 drivers/tty/hvc/hvsi.c static int (*hvsi_wait)(struct hvsi_struct *hp, int state);
hp                 99 drivers/tty/hvc/hvsi.c static inline int is_console(struct hvsi_struct *hp)
hp                101 drivers/tty/hvc/hvsi.c 	return hp->flags & HVSI_CONSOLE;
hp                104 drivers/tty/hvc/hvsi.c static inline int is_open(struct hvsi_struct *hp)
hp                107 drivers/tty/hvc/hvsi.c 	return (hp->state == HVSI_OPEN)
hp                108 drivers/tty/hvc/hvsi.c 			|| (hp->state == HVSI_WAIT_FOR_MCTRL_RESPONSE);
hp                111 drivers/tty/hvc/hvsi.c static inline void print_state(struct hvsi_struct *hp)
hp                122 drivers/tty/hvc/hvsi.c 	const char *name = (hp->state < ARRAY_SIZE(state_names))
hp                123 drivers/tty/hvc/hvsi.c 		? state_names[hp->state] : "UNKNOWN";
hp                125 drivers/tty/hvc/hvsi.c 	pr_debug("hvsi%i: state = %s\n", hp->index, name);
hp                129 drivers/tty/hvc/hvsi.c static inline void __set_state(struct hvsi_struct *hp, int state)
hp                131 drivers/tty/hvc/hvsi.c 	hp->state = state;
hp                132 drivers/tty/hvc/hvsi.c 	print_state(hp);
hp                133 drivers/tty/hvc/hvsi.c 	wake_up_all(&hp->stateq);
hp                136 drivers/tty/hvc/hvsi.c static inline void set_state(struct hvsi_struct *hp, int state)
hp                140 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                141 drivers/tty/hvc/hvsi.c 	__set_state(hp, state);
hp                142 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                156 drivers/tty/hvc/hvsi.c static inline int got_packet(const struct hvsi_struct *hp, uint8_t *packet)
hp                158 drivers/tty/hvc/hvsi.c 	if (hp->inbuf_end < packet + sizeof(struct hvsi_header))
hp                161 drivers/tty/hvc/hvsi.c 	if (hp->inbuf_end < (packet + len_packet(packet)))
hp                168 drivers/tty/hvc/hvsi.c static void compact_inbuf(struct hvsi_struct *hp, uint8_t *read_to)
hp                170 drivers/tty/hvc/hvsi.c 	int remaining = (int)(hp->inbuf_end - read_to);
hp                174 drivers/tty/hvc/hvsi.c 	if (read_to != hp->inbuf)
hp                175 drivers/tty/hvc/hvsi.c 		memmove(hp->inbuf, read_to, remaining);
hp                177 drivers/tty/hvc/hvsi.c 	hp->inbuf_end = hp->inbuf + remaining;
hp                216 drivers/tty/hvc/hvsi.c static int hvsi_read(struct hvsi_struct *hp, char *buf, int count)
hp                220 drivers/tty/hvc/hvsi.c 	got = hvc_get_chars(hp->vtermno, buf, count);
hp                225 drivers/tty/hvc/hvsi.c static void hvsi_recv_control(struct hvsi_struct *hp, uint8_t *packet,
hp                234 drivers/tty/hvc/hvsi.c 				pr_debug("hvsi%i: CD dropped\n", hp->index);
hp                235 drivers/tty/hvc/hvsi.c 				hp->mctrl &= TIOCM_CD;
hp                241 drivers/tty/hvc/hvsi.c 			pr_debug("hvsi%i: service processor came back\n", hp->index);
hp                242 drivers/tty/hvc/hvsi.c 			if (hp->state != HVSI_CLOSED) {
hp                243 drivers/tty/hvc/hvsi.c 				*to_handshake = hp;
hp                248 drivers/tty/hvc/hvsi.c 				hp->index);
hp                254 drivers/tty/hvc/hvsi.c static void hvsi_recv_response(struct hvsi_struct *hp, uint8_t *packet)
hp                259 drivers/tty/hvc/hvsi.c 	switch (hp->state) {
hp                261 drivers/tty/hvc/hvsi.c 			__set_state(hp, HVSI_WAIT_FOR_VER_QUERY);
hp                264 drivers/tty/hvc/hvsi.c 			hp->mctrl = 0;
hp                267 drivers/tty/hvc/hvsi.c 				hp->mctrl |= TIOCM_DTR;
hp                269 drivers/tty/hvc/hvsi.c 				hp->mctrl |= TIOCM_CD;
hp                270 drivers/tty/hvc/hvsi.c 			__set_state(hp, HVSI_OPEN);
hp                273 drivers/tty/hvc/hvsi.c 			printk(KERN_ERR "hvsi%i: unexpected query response: ", hp->index);
hp                280 drivers/tty/hvc/hvsi.c static int hvsi_version_respond(struct hvsi_struct *hp, uint16_t query_seqno)
hp                287 drivers/tty/hvc/hvsi.c 	packet.hdr.seqno = cpu_to_be16(atomic_inc_return(&hp->seqno));
hp                295 drivers/tty/hvc/hvsi.c 	wrote = hvc_put_chars(hp->vtermno, (char *)&packet, packet.hdr.len);
hp                298 drivers/tty/hvc/hvsi.c 			hp->index);
hp                305 drivers/tty/hvc/hvsi.c static void hvsi_recv_query(struct hvsi_struct *hp, uint8_t *packet)
hp                309 drivers/tty/hvc/hvsi.c 	switch (hp->state) {
hp                311 drivers/tty/hvc/hvsi.c 			hvsi_version_respond(hp, be16_to_cpu(query->hdr.seqno));
hp                312 drivers/tty/hvc/hvsi.c 			__set_state(hp, HVSI_OPEN);
hp                315 drivers/tty/hvc/hvsi.c 			printk(KERN_ERR "hvsi%i: unexpected query: ", hp->index);
hp                321 drivers/tty/hvc/hvsi.c static void hvsi_insert_chars(struct hvsi_struct *hp, const char *buf, int len)
hp                329 drivers/tty/hvc/hvsi.c 			hp->sysrq = 1;
hp                331 drivers/tty/hvc/hvsi.c 		} else if (hp->sysrq) {
hp                333 drivers/tty/hvc/hvsi.c 			hp->sysrq = 0;
hp                337 drivers/tty/hvc/hvsi.c 		tty_insert_flip_char(&hp->port, c, 0);
hp                350 drivers/tty/hvc/hvsi.c static bool hvsi_recv_data(struct hvsi_struct *hp, const uint8_t *packet)
hp                367 drivers/tty/hvc/hvsi.c 	hvsi_insert_chars(hp, data, datalen);
hp                375 drivers/tty/hvc/hvsi.c 		memcpy(hp->throttle_buf, data + TTY_THRESHOLD_THROTTLE, overflow);
hp                376 drivers/tty/hvc/hvsi.c 		hp->n_throttle = overflow;
hp                388 drivers/tty/hvc/hvsi.c static int hvsi_load_chunk(struct hvsi_struct *hp, struct tty_struct *tty,
hp                391 drivers/tty/hvc/hvsi.c 	uint8_t *packet = hp->inbuf;
hp                397 drivers/tty/hvc/hvsi.c 	chunklen = hvsi_read(hp, hp->inbuf_end, HVSI_MAX_READ);
hp                404 drivers/tty/hvc/hvsi.c 	dbg_dump_hex(hp->inbuf_end, chunklen);
hp                406 drivers/tty/hvc/hvsi.c 	hp->inbuf_end += chunklen;
hp                409 drivers/tty/hvc/hvsi.c 	while ((packet < hp->inbuf_end) && got_packet(hp, packet)) {
hp                413 drivers/tty/hvc/hvsi.c 			printk(KERN_ERR "hvsi%i: got malformed packet\n", hp->index);
hp                415 drivers/tty/hvc/hvsi.c 			while ((packet < hp->inbuf_end) && (!is_header(packet)))
hp                426 drivers/tty/hvc/hvsi.c 				if (!is_open(hp))
hp                428 drivers/tty/hvc/hvsi.c 				flip = hvsi_recv_data(hp, packet);
hp                431 drivers/tty/hvc/hvsi.c 				hvsi_recv_control(hp, packet, tty, handshake);
hp                434 drivers/tty/hvc/hvsi.c 				hvsi_recv_response(hp, packet);
hp                437 drivers/tty/hvc/hvsi.c 				hvsi_recv_query(hp, packet);
hp                441 drivers/tty/hvc/hvsi.c 						hp->index, header->type);
hp                454 drivers/tty/hvc/hvsi.c 	compact_inbuf(hp, packet);
hp                457 drivers/tty/hvc/hvsi.c 		tty_flip_buffer_push(&hp->port);
hp                462 drivers/tty/hvc/hvsi.c static void hvsi_send_overflow(struct hvsi_struct *hp)
hp                465 drivers/tty/hvc/hvsi.c 			hp->n_throttle);
hp                467 drivers/tty/hvc/hvsi.c 	hvsi_insert_chars(hp, hp->throttle_buf, hp->n_throttle);
hp                468 drivers/tty/hvc/hvsi.c 	hp->n_throttle = 0;
hp                477 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = (struct hvsi_struct *)arg;
hp                485 drivers/tty/hvc/hvsi.c 	tty = tty_port_tty_get(&hp->port);
hp                488 drivers/tty/hvc/hvsi.c 		spin_lock_irqsave(&hp->lock, flags);
hp                489 drivers/tty/hvc/hvsi.c 		again = hvsi_load_chunk(hp, tty, &handshake);
hp                490 drivers/tty/hvc/hvsi.c 		spin_unlock_irqrestore(&hp->lock, flags);
hp                498 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                499 drivers/tty/hvc/hvsi.c 	if (tty && hp->n_throttle && !tty_throttled(tty)) {
hp                502 drivers/tty/hvc/hvsi.c 		hvsi_send_overflow(hp);
hp                503 drivers/tty/hvc/hvsi.c 		tty_flip_buffer_push(&hp->port);
hp                505 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                513 drivers/tty/hvc/hvsi.c static int __init poll_for_state(struct hvsi_struct *hp, int state)
hp                518 drivers/tty/hvc/hvsi.c 		hvsi_interrupt(hp->virq, (void *)hp); /* get pending data */
hp                520 drivers/tty/hvc/hvsi.c 		if (hp->state == state)
hp                530 drivers/tty/hvc/hvsi.c static int wait_for_state(struct hvsi_struct *hp, int state)
hp                534 drivers/tty/hvc/hvsi.c 	if (!wait_event_timeout(hp->stateq, (hp->state == state), HVSI_TIMEOUT))
hp                540 drivers/tty/hvc/hvsi.c static int hvsi_query(struct hvsi_struct *hp, uint16_t verb)
hp                547 drivers/tty/hvc/hvsi.c 	packet.hdr.seqno = cpu_to_be16(atomic_inc_return(&hp->seqno));
hp                553 drivers/tty/hvc/hvsi.c 	wrote = hvc_put_chars(hp->vtermno, (char *)&packet, packet.hdr.len);
hp                555 drivers/tty/hvc/hvsi.c 		printk(KERN_ERR "hvsi%i: couldn't send query (%i)!\n", hp->index,
hp                563 drivers/tty/hvc/hvsi.c static int hvsi_get_mctrl(struct hvsi_struct *hp)
hp                567 drivers/tty/hvc/hvsi.c 	set_state(hp, HVSI_WAIT_FOR_MCTRL_RESPONSE);
hp                568 drivers/tty/hvc/hvsi.c 	hvsi_query(hp, VSV_SEND_MODEM_CTL_STATUS);
hp                570 drivers/tty/hvc/hvsi.c 	ret = hvsi_wait(hp, HVSI_OPEN);
hp                572 drivers/tty/hvc/hvsi.c 		printk(KERN_ERR "hvsi%i: didn't get modem flags\n", hp->index);
hp                573 drivers/tty/hvc/hvsi.c 		set_state(hp, HVSI_OPEN);
hp                577 drivers/tty/hvc/hvsi.c 	pr_debug("%s: mctrl 0x%x\n", __func__, hp->mctrl);
hp                583 drivers/tty/hvc/hvsi.c static int hvsi_set_mctrl(struct hvsi_struct *hp, uint16_t mctrl)
hp                589 drivers/tty/hvc/hvsi.c 	packet.hdr.seqno = cpu_to_be16(atomic_inc_return(&hp->seqno));
hp                600 drivers/tty/hvc/hvsi.c 	wrote = hvc_put_chars(hp->vtermno, (char *)&packet, packet.hdr.len);
hp                602 drivers/tty/hvc/hvsi.c 		printk(KERN_ERR "hvsi%i: couldn't set DTR!\n", hp->index);
hp                609 drivers/tty/hvc/hvsi.c static void hvsi_drain_input(struct hvsi_struct *hp)
hp                615 drivers/tty/hvc/hvsi.c 		if (0 == hvsi_read(hp, buf, HVSI_MAX_READ))
hp                619 drivers/tty/hvc/hvsi.c static int hvsi_handshake(struct hvsi_struct *hp)
hp                630 drivers/tty/hvc/hvsi.c 	hvsi_drain_input(hp);
hp                632 drivers/tty/hvc/hvsi.c 	set_state(hp, HVSI_WAIT_FOR_VER_RESPONSE);
hp                633 drivers/tty/hvc/hvsi.c 	ret = hvsi_query(hp, VSV_SEND_VERSION_NUMBER);
hp                635 drivers/tty/hvc/hvsi.c 		printk(KERN_ERR "hvsi%i: couldn't send version query\n", hp->index);
hp                639 drivers/tty/hvc/hvsi.c 	ret = hvsi_wait(hp, HVSI_OPEN);
hp                648 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp =
hp                651 drivers/tty/hvc/hvsi.c 	if (hvsi_handshake(hp) >= 0)
hp                654 drivers/tty/hvc/hvsi.c 	printk(KERN_ERR "hvsi%i: re-handshaking failed\n", hp->index);
hp                655 drivers/tty/hvc/hvsi.c 	if (is_console(hp)) {
hp                660 drivers/tty/hvc/hvsi.c 		printk(KERN_ERR "hvsi%i: lost console!\n", hp->index);
hp                664 drivers/tty/hvc/hvsi.c static int hvsi_put_chars(struct hvsi_struct *hp, const char *buf, int count)
hp                672 drivers/tty/hvc/hvsi.c 	packet.hdr.seqno = cpu_to_be16(atomic_inc_return(&hp->seqno));
hp                676 drivers/tty/hvc/hvsi.c 	ret = hvc_put_chars(hp->vtermno, (char *)&packet, packet.hdr.len);
hp                684 drivers/tty/hvc/hvsi.c static void hvsi_close_protocol(struct hvsi_struct *hp)
hp                689 drivers/tty/hvc/hvsi.c 	packet.hdr.seqno = cpu_to_be16(atomic_inc_return(&hp->seqno));
hp                696 drivers/tty/hvc/hvsi.c 	hvc_put_chars(hp->vtermno, (char *)&packet, packet.hdr.len);
hp                701 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp;
hp                707 drivers/tty/hvc/hvsi.c 	hp = &hvsi_ports[tty->index];
hp                709 drivers/tty/hvc/hvsi.c 	tty->driver_data = hp;
hp                712 drivers/tty/hvc/hvsi.c 	if (hp->state == HVSI_FSP_DIED)
hp                715 drivers/tty/hvc/hvsi.c 	tty_port_tty_set(&hp->port, tty);
hp                716 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                717 drivers/tty/hvc/hvsi.c 	hp->port.count++;
hp                718 drivers/tty/hvc/hvsi.c 	atomic_set(&hp->seqno, 0);
hp                719 drivers/tty/hvc/hvsi.c 	h_vio_signal(hp->vtermno, VIO_IRQ_ENABLE);
hp                720 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                722 drivers/tty/hvc/hvsi.c 	if (is_console(hp))
hp                725 drivers/tty/hvc/hvsi.c 	ret = hvsi_handshake(hp);
hp                731 drivers/tty/hvc/hvsi.c 	ret = hvsi_get_mctrl(hp);
hp                737 drivers/tty/hvc/hvsi.c 	ret = hvsi_set_mctrl(hp, hp->mctrl | TIOCM_DTR);
hp                747 drivers/tty/hvc/hvsi.c static void hvsi_flush_output(struct hvsi_struct *hp)
hp                749 drivers/tty/hvc/hvsi.c 	wait_event_timeout(hp->emptyq, (hp->n_outbuf <= 0), HVSI_TIMEOUT);
hp                752 drivers/tty/hvc/hvsi.c 	cancel_delayed_work_sync(&hp->writer);
hp                753 drivers/tty/hvc/hvsi.c 	flush_work(&hp->handshaker);
hp                759 drivers/tty/hvc/hvsi.c 	hp->n_outbuf = 0;
hp                764 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                772 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                774 drivers/tty/hvc/hvsi.c 	if (--hp->port.count == 0) {
hp                775 drivers/tty/hvc/hvsi.c 		tty_port_tty_set(&hp->port, NULL);
hp                776 drivers/tty/hvc/hvsi.c 		hp->inbuf_end = hp->inbuf; /* discard remaining partial packets */
hp                779 drivers/tty/hvc/hvsi.c 		if (!is_console(hp)) {
hp                780 drivers/tty/hvc/hvsi.c 			h_vio_signal(hp->vtermno, VIO_IRQ_DISABLE); /* no more irqs */
hp                781 drivers/tty/hvc/hvsi.c 			__set_state(hp, HVSI_CLOSED);
hp                788 drivers/tty/hvc/hvsi.c 			spin_unlock_irqrestore(&hp->lock, flags);
hp                791 drivers/tty/hvc/hvsi.c 			synchronize_irq(hp->virq);
hp                794 drivers/tty/hvc/hvsi.c 			hvsi_flush_output(hp);
hp                797 drivers/tty/hvc/hvsi.c 			hvsi_close_protocol(hp);
hp                803 drivers/tty/hvc/hvsi.c 			hvsi_drain_input(hp);
hp                805 drivers/tty/hvc/hvsi.c 			spin_lock_irqsave(&hp->lock, flags);
hp                807 drivers/tty/hvc/hvsi.c 	} else if (hp->port.count < 0)
hp                809 drivers/tty/hvc/hvsi.c 		       hp - hvsi_ports, hp->port.count);
hp                811 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                816 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                821 drivers/tty/hvc/hvsi.c 	tty_port_tty_set(&hp->port, NULL);
hp                823 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                824 drivers/tty/hvc/hvsi.c 	hp->port.count = 0;
hp                825 drivers/tty/hvc/hvsi.c 	hp->n_outbuf = 0;
hp                826 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                830 drivers/tty/hvc/hvsi.c static void hvsi_push(struct hvsi_struct *hp)
hp                834 drivers/tty/hvc/hvsi.c 	if (hp->n_outbuf <= 0)
hp                837 drivers/tty/hvc/hvsi.c 	n = hvsi_put_chars(hp, hp->outbuf, hp->n_outbuf);
hp                841 drivers/tty/hvc/hvsi.c 		hp->n_outbuf = 0;
hp                843 drivers/tty/hvc/hvsi.c 		__set_state(hp, HVSI_FSP_DIED);
hp                844 drivers/tty/hvc/hvsi.c 		printk(KERN_ERR "hvsi%i: service processor died\n", hp->index);
hp                851 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp =
hp                861 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                863 drivers/tty/hvc/hvsi.c 	pr_debug("%s: %i chars in buffer\n", __func__, hp->n_outbuf);
hp                865 drivers/tty/hvc/hvsi.c 	if (!is_open(hp)) {
hp                872 drivers/tty/hvc/hvsi.c 		schedule_delayed_work(&hp->writer, HZ);
hp                876 drivers/tty/hvc/hvsi.c 	hvsi_push(hp);
hp                877 drivers/tty/hvc/hvsi.c 	if (hp->n_outbuf > 0)
hp                878 drivers/tty/hvc/hvsi.c 		schedule_delayed_work(&hp->writer, 10);
hp                885 drivers/tty/hvc/hvsi.c 		wake_up_all(&hp->emptyq);
hp                886 drivers/tty/hvc/hvsi.c 		tty_port_tty_wakeup(&hp->port);
hp                890 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                895 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                897 drivers/tty/hvc/hvsi.c 	return N_OUTBUF - hp->n_outbuf;
hp                902 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                904 drivers/tty/hvc/hvsi.c 	return hp->n_outbuf;
hp                910 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                916 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                918 drivers/tty/hvc/hvsi.c 	pr_debug("%s: %i chars in buffer\n", __func__, hp->n_outbuf);
hp                920 drivers/tty/hvc/hvsi.c 	if (!is_open(hp)) {
hp                934 drivers/tty/hvc/hvsi.c 		BUG_ON(hp->n_outbuf < 0);
hp                935 drivers/tty/hvc/hvsi.c 		memcpy(hp->outbuf + hp->n_outbuf, source, chunksize);
hp                936 drivers/tty/hvc/hvsi.c 		hp->n_outbuf += chunksize;
hp                941 drivers/tty/hvc/hvsi.c 		hvsi_push(hp);
hp                944 drivers/tty/hvc/hvsi.c 	if (hp->n_outbuf > 0) {
hp                949 drivers/tty/hvc/hvsi.c 		schedule_delayed_work(&hp->writer, 10);
hp                953 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                968 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                972 drivers/tty/hvc/hvsi.c 	h_vio_signal(hp->vtermno, VIO_IRQ_DISABLE);
hp                977 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                982 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp                983 drivers/tty/hvc/hvsi.c 	if (hp->n_throttle) {
hp                984 drivers/tty/hvc/hvsi.c 		hvsi_send_overflow(hp);
hp                985 drivers/tty/hvc/hvsi.c 		tty_flip_buffer_push(&hp->port);
hp                987 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp                990 drivers/tty/hvc/hvsi.c 	h_vio_signal(hp->vtermno, VIO_IRQ_ENABLE);
hp                995 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp                997 drivers/tty/hvc/hvsi.c 	hvsi_get_mctrl(hp);
hp                998 drivers/tty/hvc/hvsi.c 	return hp->mctrl;
hp               1004 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = tty->driver_data;
hp               1012 drivers/tty/hvc/hvsi.c 	spin_lock_irqsave(&hp->lock, flags);
hp               1014 drivers/tty/hvc/hvsi.c 	new_mctrl = (hp->mctrl & ~clear) | set;
hp               1016 drivers/tty/hvc/hvsi.c 	if (hp->mctrl != new_mctrl) {
hp               1017 drivers/tty/hvc/hvsi.c 		hvsi_set_mctrl(hp, new_mctrl);
hp               1018 drivers/tty/hvc/hvsi.c 		hp->mctrl = new_mctrl;
hp               1020 drivers/tty/hvc/hvsi.c 	spin_unlock_irqrestore(&hp->lock, flags);
hp               1060 drivers/tty/hvc/hvsi.c 		struct hvsi_struct *hp = &hvsi_ports[i];
hp               1063 drivers/tty/hvc/hvsi.c 		tty_port_link_device(&hp->port, hvsi_driver, i);
hp               1065 drivers/tty/hvc/hvsi.c 		ret = request_irq(hp->virq, hvsi_interrupt, 0, "hvsi", hp);
hp               1068 drivers/tty/hvc/hvsi.c 				hp->virq, ret);
hp               1086 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp = &hvsi_ports[console->index];
hp               1092 drivers/tty/hvc/hvsi.c 	if (!is_open(hp))
hp               1110 drivers/tty/hvc/hvsi.c 			ret = hvsi_put_chars(hp, c, i);
hp               1127 drivers/tty/hvc/hvsi.c 	struct hvsi_struct *hp;
hp               1132 drivers/tty/hvc/hvsi.c 	hp = &hvsi_ports[console->index];
hp               1135 drivers/tty/hvc/hvsi.c 	hvsi_close_protocol(hp);
hp               1137 drivers/tty/hvc/hvsi.c 	ret = hvsi_handshake(hp);
hp               1141 drivers/tty/hvc/hvsi.c 	ret = hvsi_get_mctrl(hp);
hp               1145 drivers/tty/hvc/hvsi.c 	ret = hvsi_set_mctrl(hp, hp->mctrl | TIOCM_DTR);
hp               1149 drivers/tty/hvc/hvsi.c 	hp->flags |= HVSI_CONSOLE;
hp               1171 drivers/tty/hvc/hvsi.c 		struct hvsi_struct *hp;
hp               1184 drivers/tty/hvc/hvsi.c 		hp = &hvsi_ports[hvsi_count];
hp               1185 drivers/tty/hvc/hvsi.c 		INIT_DELAYED_WORK(&hp->writer, hvsi_write_worker);
hp               1186 drivers/tty/hvc/hvsi.c 		INIT_WORK(&hp->handshaker, hvsi_handshaker);
hp               1187 drivers/tty/hvc/hvsi.c 		init_waitqueue_head(&hp->emptyq);
hp               1188 drivers/tty/hvc/hvsi.c 		init_waitqueue_head(&hp->stateq);
hp               1189 drivers/tty/hvc/hvsi.c 		spin_lock_init(&hp->lock);
hp               1190 drivers/tty/hvc/hvsi.c 		tty_port_init(&hp->port);
hp               1191 drivers/tty/hvc/hvsi.c 		hp->index = hvsi_count;
hp               1192 drivers/tty/hvc/hvsi.c 		hp->inbuf_end = hp->inbuf;
hp               1193 drivers/tty/hvc/hvsi.c 		hp->state = HVSI_CLOSED;
hp               1194 drivers/tty/hvc/hvsi.c 		hp->vtermno = be32_to_cpup(vtermno);
hp               1195 drivers/tty/hvc/hvsi.c 		hp->virq = irq_create_mapping(NULL, be32_to_cpup(irq));
hp               1196 drivers/tty/hvc/hvsi.c 		if (hp->virq == 0) {
hp               1199 drivers/tty/hvc/hvsi.c 			tty_port_destroy(&hp->port);
hp                374 drivers/tty/hvc/hvsi_lib.c int hvsilib_open(struct hvsi_priv *pv, struct hvc_struct *hp)
hp                379 drivers/tty/hvc/hvsi_lib.c 	pv->tty = tty_port_tty_get(&hp->port);
hp                386 drivers/tty/hvc/hvsi_lib.c void hvsilib_close(struct hvsi_priv *pv, struct hvc_struct *hp)
hp                397 drivers/tty/hvc/hvsi_lib.c 		spin_lock_irqsave(&hp->lock, flags);
hp                399 drivers/tty/hvc/hvsi_lib.c 		spin_unlock_irqrestore(&hp->lock, flags);
hp                570 drivers/tty/vcc.c 	struct mdesc_handle *hp;
hp                618 drivers/tty/vcc.c 	hp = mdesc_grab();
hp                620 drivers/tty/vcc.c 	node = vio_vdev_node(hp, vdev);
hp                623 drivers/tty/vcc.c 		mdesc_release(hp);
hp                627 drivers/tty/vcc.c 	domain = mdesc_get_property(hp, node, "vcc-domain-name", NULL);
hp                630 drivers/tty/vcc.c 		mdesc_release(hp);
hp                635 drivers/tty/vcc.c 	mdesc_release(hp);
hp                368 include/acpi/acpi_bus.h 	struct acpi_hotplug_context *hp;
hp                456 include/acpi/acpi_bus.h 				       struct acpi_hotplug_context *hp)
hp                458 include/acpi/acpi_bus.h 	hp->self = adev;
hp                459 include/acpi/acpi_bus.h 	adev->hp = hp;
hp                463 include/acpi/acpi_bus.h 				struct acpi_hotplug_context *hp,
hp               1631 include/net/tcp.h int tcp_md5_hash_key(struct tcp_md5sig_pool *hp,
hp                 45 include/scsi/fc/fc_fcoe.h #define FC_FCOE_DECAPS_VER(hp)	    ((hp)->fcoe_ver >> 4)
hp                 46 include/scsi/fc/fc_fcoe.h #define FC_FCOE_ENCAPS_VER(hp, ver) ((hp)->fcoe_ver = (ver) << 4)
hp               4815 net/core/skbuff.c 			struct ipv6_opt_hdr *hp;
hp               4824 net/core/skbuff.c 			hp = OPT_HDR(struct ipv6_opt_hdr, skb, off);
hp               4825 net/core/skbuff.c 			nexthdr = hp->nexthdr;
hp               4826 net/core/skbuff.c 			off += ipv6_optlen(hp);
hp               4830 net/core/skbuff.c 			struct ip_auth_hdr *hp;
hp               4839 net/core/skbuff.c 			hp = OPT_HDR(struct ip_auth_hdr, skb, off);
hp               4840 net/core/skbuff.c 			nexthdr = hp->nexthdr;
hp               4841 net/core/skbuff.c 			off += ipv6_authlen(hp);
hp               4845 net/core/skbuff.c 			struct frag_hdr *hp;
hp               4854 net/core/skbuff.c 			hp = OPT_HDR(struct frag_hdr, skb, off);
hp               4856 net/core/skbuff.c 			if (hp->frag_off & htons(IP6_OFFSET | IP6_MF))
hp               4859 net/core/skbuff.c 			nexthdr = hp->nexthdr;
hp                108 net/ipv4/netfilter/nf_socket_ipv4.c 		struct udphdr *hp;
hp                110 net/ipv4/netfilter/nf_socket_ipv4.c 		hp = skb_header_pointer(skb, ip_hdrlen(skb),
hp                112 net/ipv4/netfilter/nf_socket_ipv4.c 					sizeof(*hp) : sizeof(_hdr), &_hdr);
hp                113 net/ipv4/netfilter/nf_socket_ipv4.c 		if (hp == NULL)
hp                118 net/ipv4/netfilter/nf_socket_ipv4.c 		sport = hp->source;
hp                120 net/ipv4/netfilter/nf_socket_ipv4.c 		dport = hp->dest;
hp                123 net/ipv4/netfilter/nf_socket_ipv4.c 			ip_hdrlen(skb) + __tcp_hdrlen((struct tcphdr *)hp) :
hp                124 net/ipv4/netfilter/nf_socket_ipv4.c 			ip_hdrlen(skb) + sizeof(*hp);
hp                 23 net/ipv4/netfilter/nf_tproxy_ipv4.c 	struct tcphdr _hdr, *hp;
hp                 25 net/ipv4/netfilter/nf_tproxy_ipv4.c 	hp = skb_header_pointer(skb, ip_hdrlen(skb), sizeof(_hdr), &_hdr);
hp                 26 net/ipv4/netfilter/nf_tproxy_ipv4.c 	if (hp == NULL) {
hp                 31 net/ipv4/netfilter/nf_tproxy_ipv4.c 	if (hp->syn && !hp->rst && !hp->ack && !hp->fin) {
hp                 38 net/ipv4/netfilter/nf_tproxy_ipv4.c 					    hp->source, lport ? lport : hp->dest,
hp                 86 net/ipv4/netfilter/nf_tproxy_ipv4.c 		struct tcphdr _hdr, *hp;
hp                 88 net/ipv4/netfilter/nf_tproxy_ipv4.c 		hp = skb_header_pointer(skb, ip_hdrlen(skb),
hp                 90 net/ipv4/netfilter/nf_tproxy_ipv4.c 		if (hp == NULL)
hp                 97 net/ipv4/netfilter/nf_tproxy_ipv4.c 						      __tcp_hdrlen(hp),
hp               3806 net/ipv4/tcp.c int tcp_md5_hash_skb_data(struct tcp_md5sig_pool *hp,
hp               3811 net/ipv4/tcp.c 	struct ahash_request *req = hp->md5_req;
hp               3838 net/ipv4/tcp.c 		if (tcp_md5_hash_skb_data(hp, frag_iter, 0))
hp               3845 net/ipv4/tcp.c int tcp_md5_hash_key(struct tcp_md5sig_pool *hp, const struct tcp_md5sig_key *key)
hp               3850 net/ipv4/tcp.c 	ahash_request_set_crypt(hp->md5_req, &sg, NULL, key->keylen);
hp               3851 net/ipv4/tcp.c 	return crypto_ahash_update(hp->md5_req);
hp               1184 net/ipv4/tcp_ipv4.c static int tcp_v4_md5_hash_headers(struct tcp_md5sig_pool *hp,
hp               1192 net/ipv4/tcp_ipv4.c 	bp = hp->scratch;
hp               1204 net/ipv4/tcp_ipv4.c 	ahash_request_set_crypt(hp->md5_req, &sg, NULL,
hp               1206 net/ipv4/tcp_ipv4.c 	return crypto_ahash_update(hp->md5_req);
hp               1212 net/ipv4/tcp_ipv4.c 	struct tcp_md5sig_pool *hp;
hp               1215 net/ipv4/tcp_ipv4.c 	hp = tcp_get_md5sig_pool();
hp               1216 net/ipv4/tcp_ipv4.c 	if (!hp)
hp               1218 net/ipv4/tcp_ipv4.c 	req = hp->md5_req;
hp               1222 net/ipv4/tcp_ipv4.c 	if (tcp_v4_md5_hash_headers(hp, daddr, saddr, th, th->doff << 2))
hp               1224 net/ipv4/tcp_ipv4.c 	if (tcp_md5_hash_key(hp, key))
hp               1244 net/ipv4/tcp_ipv4.c 	struct tcp_md5sig_pool *hp;
hp               1258 net/ipv4/tcp_ipv4.c 	hp = tcp_get_md5sig_pool();
hp               1259 net/ipv4/tcp_ipv4.c 	if (!hp)
hp               1261 net/ipv4/tcp_ipv4.c 	req = hp->md5_req;
hp               1266 net/ipv4/tcp_ipv4.c 	if (tcp_v4_md5_hash_headers(hp, daddr, saddr, th, skb->len))
hp               1268 net/ipv4/tcp_ipv4.c 	if (tcp_md5_hash_skb_data(hp, skb, th->doff << 2))
hp               1270 net/ipv4/tcp_ipv4.c 	if (tcp_md5_hash_key(hp, key))
hp                 80 net/ipv6/exthdrs_core.c 		struct ipv6_opt_hdr _hdr, *hp;
hp                 85 net/ipv6/exthdrs_core.c 		hp = skb_header_pointer(skb, start, sizeof(_hdr), &_hdr);
hp                 86 net/ipv6/exthdrs_core.c 		if (!hp)
hp                103 net/ipv6/exthdrs_core.c 			hdrlen = ipv6_authlen(hp);
hp                105 net/ipv6/exthdrs_core.c 			hdrlen = ipv6_optlen(hp);
hp                107 net/ipv6/exthdrs_core.c 		nexthdr = hp->nexthdr;
hp                207 net/ipv6/exthdrs_core.c 		struct ipv6_opt_hdr _hdr, *hp;
hp                217 net/ipv6/exthdrs_core.c 		hp = skb_header_pointer(skb, start, sizeof(_hdr), &_hdr);
hp                218 net/ipv6/exthdrs_core.c 		if (!hp)
hp                251 net/ipv6/exthdrs_core.c 				    ((!ipv6_ext_hdr(hp->nexthdr)) ||
hp                252 net/ipv6/exthdrs_core.c 				     hp->nexthdr == NEXTHDR_NONE)) {
hp                255 net/ipv6/exthdrs_core.c 					return hp->nexthdr;
hp                267 net/ipv6/exthdrs_core.c 			hdrlen = ipv6_authlen(hp);
hp                269 net/ipv6/exthdrs_core.c 			hdrlen = ipv6_optlen(hp);
hp                272 net/ipv6/exthdrs_core.c 			nexthdr = hp->nexthdr;
hp                 46 net/ipv6/netfilter/ip6t_ipv6header.c 		const struct ipv6_opt_hdr *hp;
hp                 64 net/ipv6/netfilter/ip6t_ipv6header.c 		hp = skb_header_pointer(skb, ptr, sizeof(_hdr), &_hdr);
hp                 65 net/ipv6/netfilter/ip6t_ipv6header.c 		if (!hp) {
hp                 74 net/ipv6/netfilter/ip6t_ipv6header.c 			hdrlen = ipv6_authlen(hp);
hp                 76 net/ipv6/netfilter/ip6t_ipv6header.c 			hdrlen = ipv6_optlen(hp);
hp                 99 net/ipv6/netfilter/ip6t_ipv6header.c 		nexthdr = hp->nexthdr;
hp                 75 net/ipv6/netfilter/nf_log_ipv6.c 		const struct ipv6_opt_hdr *hp;
hp                 77 net/ipv6/netfilter/nf_log_ipv6.c 		hp = skb_header_pointer(skb, ptr, sizeof(_hdr), &_hdr);
hp                 78 net/ipv6/netfilter/nf_log_ipv6.c 		if (hp == NULL) {
hp                125 net/ipv6/netfilter/nf_log_ipv6.c 			hdrlen = ipv6_optlen(hp);
hp                158 net/ipv6/netfilter/nf_log_ipv6.c 			hdrlen = ipv6_authlen(hp);
hp                197 net/ipv6/netfilter/nf_log_ipv6.c 		currenthdr = hp->nexthdr;
hp                115 net/ipv6/netfilter/nf_socket_ipv6.c 		struct udphdr *hp;
hp                117 net/ipv6/netfilter/nf_socket_ipv6.c 		hp = skb_header_pointer(skb, thoff, tproto == IPPROTO_UDP ?
hp                118 net/ipv6/netfilter/nf_socket_ipv6.c 					sizeof(*hp) : sizeof(_hdr), &_hdr);
hp                119 net/ipv6/netfilter/nf_socket_ipv6.c 		if (hp == NULL)
hp                123 net/ipv6/netfilter/nf_socket_ipv6.c 		sport = hp->source;
hp                125 net/ipv6/netfilter/nf_socket_ipv6.c 		dport = hp->dest;
hp                128 net/ipv6/netfilter/nf_socket_ipv6.c 			thoff + __tcp_hdrlen((struct tcphdr *)hp) :
hp                129 net/ipv6/netfilter/nf_socket_ipv6.c 			thoff + sizeof(*hp);
hp                 46 net/ipv6/netfilter/nf_tproxy_ipv6.c 	struct tcphdr _hdr, *hp;
hp                 48 net/ipv6/netfilter/nf_tproxy_ipv6.c 	hp = skb_header_pointer(skb, thoff, sizeof(_hdr), &_hdr);
hp                 49 net/ipv6/netfilter/nf_tproxy_ipv6.c 	if (hp == NULL) {
hp                 54 net/ipv6/netfilter/nf_tproxy_ipv6.c 	if (hp->syn && !hp->rst && !hp->ack && !hp->fin) {
hp                 62 net/ipv6/netfilter/nf_tproxy_ipv6.c 					    hp->source,
hp                 63 net/ipv6/netfilter/nf_tproxy_ipv6.c 					    lport ? lport : hp->dest,
hp                 87 net/ipv6/netfilter/nf_tproxy_ipv6.c 		struct tcphdr _hdr, *hp;
hp                 89 net/ipv6/netfilter/nf_tproxy_ipv6.c 		hp = skb_header_pointer(skb, thoff,
hp                 91 net/ipv6/netfilter/nf_tproxy_ipv6.c 		if (hp == NULL)
hp                 97 net/ipv6/netfilter/nf_tproxy_ipv6.c 						   thoff + __tcp_hdrlen(hp),
hp                593 net/ipv6/tcp_ipv6.c static int tcp_v6_md5_hash_headers(struct tcp_md5sig_pool *hp,
hp                602 net/ipv6/tcp_ipv6.c 	bp = hp->scratch;
hp                614 net/ipv6/tcp_ipv6.c 	ahash_request_set_crypt(hp->md5_req, &sg, NULL,
hp                616 net/ipv6/tcp_ipv6.c 	return crypto_ahash_update(hp->md5_req);
hp                623 net/ipv6/tcp_ipv6.c 	struct tcp_md5sig_pool *hp;
hp                626 net/ipv6/tcp_ipv6.c 	hp = tcp_get_md5sig_pool();
hp                627 net/ipv6/tcp_ipv6.c 	if (!hp)
hp                629 net/ipv6/tcp_ipv6.c 	req = hp->md5_req;
hp                633 net/ipv6/tcp_ipv6.c 	if (tcp_v6_md5_hash_headers(hp, daddr, saddr, th, th->doff << 2))
hp                635 net/ipv6/tcp_ipv6.c 	if (tcp_md5_hash_key(hp, key))
hp                657 net/ipv6/tcp_ipv6.c 	struct tcp_md5sig_pool *hp;
hp                670 net/ipv6/tcp_ipv6.c 	hp = tcp_get_md5sig_pool();
hp                671 net/ipv6/tcp_ipv6.c 	if (!hp)
hp                673 net/ipv6/tcp_ipv6.c 	req = hp->md5_req;
hp                678 net/ipv6/tcp_ipv6.c 	if (tcp_v6_md5_hash_headers(hp, daddr, saddr, th, skb->len))
hp                680 net/ipv6/tcp_ipv6.c 	if (tcp_md5_hash_skb_data(hp, skb, th->doff << 2))
hp                682 net/ipv6/tcp_ipv6.c 	if (tcp_md5_hash_key(hp, key))
hp                 28 net/netfilter/nf_conntrack_proto_icmp.c 	const struct icmphdr *hp;
hp                 31 net/netfilter/nf_conntrack_proto_icmp.c 	hp = skb_header_pointer(skb, dataoff, sizeof(_hdr), &_hdr);
hp                 32 net/netfilter/nf_conntrack_proto_icmp.c 	if (hp == NULL)
hp                 35 net/netfilter/nf_conntrack_proto_icmp.c 	tuple->dst.u.icmp.type = hp->type;
hp                 36 net/netfilter/nf_conntrack_proto_icmp.c 	tuple->src.u.icmp.id = hp->un.echo.id;
hp                 37 net/netfilter/nf_conntrack_proto_icmp.c 	tuple->dst.u.icmp.code = hp->code;
hp                 34 net/netfilter/nf_conntrack_proto_icmpv6.c 	const struct icmp6hdr *hp;
hp                 37 net/netfilter/nf_conntrack_proto_icmpv6.c 	hp = skb_header_pointer(skb, dataoff, sizeof(_hdr), &_hdr);
hp                 38 net/netfilter/nf_conntrack_proto_icmpv6.c 	if (hp == NULL)
hp                 40 net/netfilter/nf_conntrack_proto_icmpv6.c 	tuple->dst.u.icmp.type = hp->icmp6_type;
hp                 41 net/netfilter/nf_conntrack_proto_icmpv6.c 	tuple->src.u.icmp.id = hp->icmp6_identifier;
hp                 42 net/netfilter/nf_conntrack_proto_icmpv6.c 	tuple->dst.u.icmp.code = hp->icmp6_code;
hp                 28 net/netfilter/nft_tproxy.c 	struct udphdr _hdr, *hp;
hp                 33 net/netfilter/nft_tproxy.c 	hp = skb_header_pointer(skb, ip_hdrlen(skb), sizeof(_hdr), &_hdr);
hp                 34 net/netfilter/nft_tproxy.c 	if (!hp) {
hp                 45 net/netfilter/nft_tproxy.c 				   hp->source, hp->dest,
hp                 55 net/netfilter/nft_tproxy.c 		tport = hp->dest;
hp                 67 net/netfilter/nft_tproxy.c 					   hp->source, tport,
hp                 87 net/netfilter/nft_tproxy.c 	struct udphdr _hdr, *hp;
hp                100 net/netfilter/nft_tproxy.c 	hp = skb_header_pointer(skb, thoff, sizeof(_hdr), &_hdr);
hp                101 net/netfilter/nft_tproxy.c 	if (hp == NULL) {
hp                112 net/netfilter/nft_tproxy.c 				   hp->source, hp->dest,
hp                122 net/netfilter/nft_tproxy.c 		tport = hp->dest;
hp                138 net/netfilter/nft_tproxy.c 					   hp->source, tport,
hp                 63 net/netfilter/xt_HMARK.c 	union hmark_ports hp;
hp                 66 net/netfilter/xt_HMARK.c 	hp.b32 = (uports->b32 & info->port_mask.b32) | info->port_set.b32;
hp                 67 net/netfilter/xt_HMARK.c 	src = ntohs(hp.b16.src);
hp                 68 net/netfilter/xt_HMARK.c 	dst = ntohs(hp.b16.dst);
hp                 40 net/netfilter/xt_TPROXY.c 	struct udphdr _hdr, *hp;
hp                 43 net/netfilter/xt_TPROXY.c 	hp = skb_header_pointer(skb, ip_hdrlen(skb), sizeof(_hdr), &_hdr);
hp                 44 net/netfilter/xt_TPROXY.c 	if (hp == NULL)
hp                 53 net/netfilter/xt_TPROXY.c 				   hp->source, hp->dest,
hp                 58 net/netfilter/xt_TPROXY.c 		lport = hp->dest;
hp                 69 net/netfilter/xt_TPROXY.c 					   hp->source, lport,
hp                 79 net/netfilter/xt_TPROXY.c 			 iph->protocol, &iph->daddr, ntohs(hp->dest),
hp                 87 net/netfilter/xt_TPROXY.c 		 iph->protocol, &iph->saddr, ntohs(hp->source),
hp                 88 net/netfilter/xt_TPROXY.c 		 &iph->daddr, ntohs(hp->dest), skb->mark);
hp                117 net/netfilter/xt_TPROXY.c 	struct udphdr _hdr, *hp;
hp                130 net/netfilter/xt_TPROXY.c 	hp = skb_header_pointer(skb, thoff, sizeof(_hdr), &_hdr);
hp                131 net/netfilter/xt_TPROXY.c 	if (hp == NULL) {
hp                142 net/netfilter/xt_TPROXY.c 				   hp->source, hp->dest,
hp                146 net/netfilter/xt_TPROXY.c 	lport = tgi->lport ? tgi->lport : hp->dest;
hp                163 net/netfilter/xt_TPROXY.c 					   hp->source, lport,
hp                173 net/netfilter/xt_TPROXY.c 			 tproto, &iph->saddr, ntohs(hp->source),
hp                181 net/netfilter/xt_TPROXY.c 		 tproto, &iph->saddr, ntohs(hp->source),
hp                182 net/netfilter/xt_TPROXY.c 		 &iph->daddr, ntohs(hp->dest), skb->mark);
hp                165 net/sunrpc/svcauth.c 	struct auth_domain *hp;
hp                172 net/sunrpc/svcauth.c 	hlist_for_each_entry(hp, head, hash) {
hp                173 net/sunrpc/svcauth.c 		if (strcmp(hp->name, name)==0) {
hp                174 net/sunrpc/svcauth.c 			kref_get(&hp->ref);
hp                176 net/sunrpc/svcauth.c 			return hp;
hp                188 net/sunrpc/svcauth.c 	struct auth_domain *hp;
hp                194 net/sunrpc/svcauth.c 	hlist_for_each_entry_rcu(hp, head, hash) {
hp                195 net/sunrpc/svcauth.c 		if (strcmp(hp->name, name)==0) {
hp                196 net/sunrpc/svcauth.c 			if (!kref_get_unless_zero(&hp->ref))
hp                197 net/sunrpc/svcauth.c 				hp = NULL;
hp                199 net/sunrpc/svcauth.c 			return hp;
hp                754 security/security.c 	struct security_hook_list *hp;
hp                765 security/security.c 	hlist_for_each_entry(hp, &security_hook_heads.vm_enough_memory, list) {
hp                766 security/security.c 		rc = hp->hook.vm_enough_memory(mm, pages);
hp               1305 security/security.c 	struct security_hook_list *hp;
hp               1313 security/security.c 	hlist_for_each_entry(hp, &security_hook_heads.inode_getsecurity, list) {
hp               1314 security/security.c 		rc = hp->hook.inode_getsecurity(inode, name, buffer, alloc);
hp               1323 security/security.c 	struct security_hook_list *hp;
hp               1331 security/security.c 	hlist_for_each_entry(hp, &security_hook_heads.inode_setsecurity, list) {
hp               1332 security/security.c 		rc = hp->hook.inode_setsecurity(inode, name, value, size,
hp               1712 security/security.c 	struct security_hook_list *hp;
hp               1714 security/security.c 	hlist_for_each_entry(hp, &security_hook_heads.task_prctl, list) {
hp               1715 security/security.c 		thisrc = hp->hook.task_prctl(option, arg2, arg3, arg4, arg5);
hp               1881 security/security.c 	struct security_hook_list *hp;
hp               1883 security/security.c 	hlist_for_each_entry(hp, &security_hook_heads.getprocattr, list) {
hp               1884 security/security.c 		if (lsm != NULL && strcmp(lsm, hp->lsm))
hp               1886 security/security.c 		return hp->hook.getprocattr(p, name, value);
hp               1894 security/security.c 	struct security_hook_list *hp;
hp               1896 security/security.c 	hlist_for_each_entry(hp, &security_hook_heads.setprocattr, list) {
hp               1897 security/security.c 		if (lsm != NULL && strcmp(lsm, hp->lsm))
hp               1899 security/security.c 		return hp->hook.setprocattr(name, value, size);
hp               2285 security/security.c 	struct security_hook_list *hp;
hp               2297 security/security.c 	hlist_for_each_entry(hp, &security_hook_heads.xfrm_state_pol_flow_match,
hp               2299 security/security.c 		rc = hp->hook.xfrm_state_pol_flow_match(x, xp, fl);
hp                 76 sound/pci/hda/patch_analog.c 				hda_nid_t hp)
hp                 81 sound/pci/hda/patch_analog.c 	if (snd_hda_query_pin_caps(codec, hp) & AC_PINCAP_EAPD)
hp                 82 sound/pci/hda/patch_analog.c 		snd_hda_codec_write(codec, hp, 0, AC_VERB_SET_EAPD_BTLENABLE,
hp                443 sound/soc/codecs/hdmi-codec.c 	struct hdmi_codec_params hp = {
hp                457 sound/soc/codecs/hdmi-codec.c 	ret = snd_pcm_create_iec958_consumer_hw_params(params, hp.iec.status,
hp                458 sound/soc/codecs/hdmi-codec.c 						       sizeof(hp.iec.status));
hp                465 sound/soc/codecs/hdmi-codec.c 	hdmi_audio_infoframe_init(&hp.cea);
hp                466 sound/soc/codecs/hdmi-codec.c 	hp.cea.channels = params_channels(params);
hp                467 sound/soc/codecs/hdmi-codec.c 	hp.cea.coding_type = HDMI_AUDIO_CODING_TYPE_STREAM;
hp                468 sound/soc/codecs/hdmi-codec.c 	hp.cea.sample_size = HDMI_AUDIO_SAMPLE_SIZE_STREAM;
hp                469 sound/soc/codecs/hdmi-codec.c 	hp.cea.sample_frequency = HDMI_AUDIO_SAMPLE_FREQUENCY_STREAM;
hp                472 sound/soc/codecs/hdmi-codec.c 	idx = hdmi_codec_get_ch_alloc_table_idx(hcp, hp.cea.channels);
hp                479 sound/soc/codecs/hdmi-codec.c 	hp.cea.channel_allocation = hdmi_codec_channel_alloc[idx].ca_id;
hp                482 sound/soc/codecs/hdmi-codec.c 	hp.sample_width = params_width(params);
hp                483 sound/soc/codecs/hdmi-codec.c 	hp.sample_rate = params_rate(params);
hp                484 sound/soc/codecs/hdmi-codec.c 	hp.channels = params_channels(params);
hp                487 sound/soc/codecs/hdmi-codec.c 				       cf, &hp);
hp               4307 sound/soc/codecs/madera.c 	int refdiv, fref, fout, lockdet_thr, fbdiv, hp, fast_clk, fllgcd;
hp               4352 sound/soc/codecs/madera.c 		hp = 0x3;
hp               4356 sound/soc/codecs/madera.c 		hp = 0x0;
hp               4382 sound/soc/codecs/madera.c 		       lockdet_thr, hp, fbdiv);
hp               4431 sound/soc/codecs/madera.c 	val = hp << MADERA_FLL1_HP_SHIFT;
hp                350 sound/soc/codecs/rt274.c static int rt274_jack_detect(struct rt274_priv *rt274, bool *hp, bool *mic)
hp                355 sound/soc/codecs/rt274.c 	*hp = false;
hp                365 sound/soc/codecs/rt274.c 	*hp = buf & 0x80000000;
hp                372 sound/soc/codecs/rt274.c 	pr_debug("*hp = %d *mic = %d\n", *hp, *mic);
hp                382 sound/soc/codecs/rt274.c 	bool hp = false;
hp                385 sound/soc/codecs/rt274.c 	if (rt274_jack_detect(rt274, &hp, &mic) < 0)
hp                388 sound/soc/codecs/rt274.c 	if (hp)
hp                952 sound/soc/codecs/rt274.c 	bool hp = false;
hp                960 sound/soc/codecs/rt274.c 	ret = rt274_jack_detect(rt274, &hp, &mic);
hp                963 sound/soc/codecs/rt274.c 		if (hp)
hp                212 sound/soc/codecs/rt286.c static int rt286_jack_detect(struct rt286_priv *rt286, bool *hp, bool *mic)
hp                217 sound/soc/codecs/rt286.c 	*hp = false;
hp                227 sound/soc/codecs/rt286.c 		*hp = buf & 0x80000000;
hp                228 sound/soc/codecs/rt286.c 		if (*hp) {
hp                271 sound/soc/codecs/rt286.c 		*hp = buf & 0x80000000;
hp                279 sound/soc/codecs/rt286.c 	if (!*hp)
hp                291 sound/soc/codecs/rt286.c 	bool hp = false;
hp                294 sound/soc/codecs/rt286.c 	rt286_jack_detect(rt286, &hp, &mic);
hp                296 sound/soc/codecs/rt286.c 	if (hp)
hp                915 sound/soc/codecs/rt286.c 	bool hp = false;
hp                919 sound/soc/codecs/rt286.c 	rt286_jack_detect(rt286, &hp, &mic);
hp                924 sound/soc/codecs/rt286.c 	if (hp)
hp                219 sound/soc/codecs/rt298.c static int rt298_jack_detect(struct rt298_priv *rt298, bool *hp, bool *mic)
hp                224 sound/soc/codecs/rt298.c 	*hp = false;
hp                234 sound/soc/codecs/rt298.c 		*hp = buf & 0x80000000;
hp                235 sound/soc/codecs/rt298.c 		if (*hp == rt298->is_hp_in)
hp                237 sound/soc/codecs/rt298.c 		rt298->is_hp_in = *hp;
hp                238 sound/soc/codecs/rt298.c 		if (*hp) {
hp                286 sound/soc/codecs/rt298.c 		*hp = buf & 0x80000000;
hp                294 sound/soc/codecs/rt298.c 	if (!*hp)
hp                298 sound/soc/codecs/rt298.c 	pr_debug("*hp = %d *mic = %d\n", *hp, *mic);
hp                308 sound/soc/codecs/rt298.c 	bool hp = false;
hp                311 sound/soc/codecs/rt298.c 	if (rt298_jack_detect(rt298, &hp, &mic) < 0)
hp                314 sound/soc/codecs/rt298.c 	if (hp)
hp                328 sound/soc/codecs/rt298.c 	bool hp = false;
hp                344 sound/soc/codecs/rt298.c 	rt298_jack_detect(rt298, &hp, &mic);
hp                345 sound/soc/codecs/rt298.c 	if (hp)
hp                979 sound/soc/codecs/rt298.c 	bool hp = false;
hp                983 sound/soc/codecs/rt298.c 	ret = rt298_jack_detect(rt298, &hp, &mic);
hp                989 sound/soc/codecs/rt298.c 		if (hp)
hp                 44 sound/soc/ti/n810.c 	int hp = 0, line1l = 0;
hp                 51 sound/soc/ti/n810.c 		hp = 1;
hp                 65 sound/soc/ti/n810.c 	if (hp)
hp                 49 sound/soc/ti/rx51.c 	int hp = 0, hs = 0, tvout = 0;
hp                 54 sound/soc/ti/rx51.c 		hp = 1;
hp                 60 sound/soc/ti/rx51.c 		hp = 1;
hp                 74 sound/soc/ti/rx51.c 	if (hp)
hp                 16 tools/virtio/linux/dma-mapping.h #define dma_alloc_coherent(d, s, hp, f) ({ \
hp                 18 tools/virtio/linux/dma-mapping.h 	*(hp) = (unsigned long)__dma_alloc_coherent_p; \