/
usr
/
src
/
linux-headers-5.15.0-190
/
arch
/
powerpc
/
include
/
asm
/
/usr/src/linux-headers-5.15.0-190/arch/powerpc/include/asm
mkdir
upload
Name
Size
Mode
Actions
book3s/
-
0755
rm
nohash/
-
0755
rm
vdso/
-
0755
rm
8xx_immap.h
14099
0644
edit
dl
rm
accounting.h
908
0644
edit
dl
rm
agp.h
525
0644
edit
dl
rm
archrandom.h
838
0644
edit
dl
rm
asm-compat.h
1882
0644
edit
dl
rm
asm-const.h
468
0644
edit
dl
rm
asm-offsets.h
35
0644
edit
dl
rm
asm-prototypes.h
5130
0644
edit
dl
rm
async_tx.h
908
0644
edit
dl
rm
atomic.h
14267
0644
edit
dl
rm
backlight.h
1115
0644
edit
dl
rm
barrier.h
3977
0644
edit
dl
rm
bitops.h
7913
0644
edit
dl
rm
bootx.h
1142
0644
edit
dl
rm
bpf_perf_event.h
233
0644
edit
dl
rm
btext.h
1006
0644
edit
dl
rm
bug.h
4090
0644
edit
dl
rm
cache.h
2888
0644
edit
dl
rm
cacheflush.h
3851
0644
edit
dl
rm
cell-pmu.h
3496
0644
edit
dl
rm
cell-regs.h
9799
0644
edit
dl
rm
checksum.h
5723
0644
edit
dl
rm
clocksource.h
185
0644
edit
dl
rm
cmpxchg.h
12280
0644
edit
dl
rm
code-patching-asm.h
397
0644
edit
dl
rm
code-patching.h
5443
0644
edit
dl
rm
compat.h
3304
0644
edit
dl
rm
context_tracking.h
245
0644
edit
dl
rm
copro.h
593
0644
edit
dl
rm
cpm.h
25
0644
edit
dl
rm
cpm1.h
21711
0644
edit
dl
rm
cpm2.h
49598
0644
edit
dl
rm
cpufeature.h
998
0644
edit
dl
rm
cpuidle.h
3407
0644
edit
dl
rm
cputable.h
23211
0644
edit
dl
rm
cputhreads.h
3856
0644
edit
dl
rm
cputime.h
3069
0644
edit
dl
rm
cpu_has_feature.h
1339
0644
edit
dl
rm
cpu_setup_power.h
507
0644
edit
dl
rm
crashdump-ppc64.h
624
0644
edit
dl
rm
current.h
680
0644
edit
dl
rm
dbdma.h
3809
0644
edit
dl
rm
dbell.h
4025
0644
edit
dl
rm
dcr-generic.h
930
0644
edit
dl
rm
dcr-mmio.h
1026
0644
edit
dl
rm
dcr-native.h
3859
0644
edit
dl
rm
dcr-regs.h
5846
0644
edit
dl
rm
dcr.h
2108
0644
edit
dl
rm
debug.h
1886
0644
edit
dl
rm
delay.h
3297
0644
edit
dl
rm
device.h
1016
0644
edit
dl
rm
disassemble.h
2189
0644
edit
dl
rm
dma-direct.h
391
0644
edit
dl
rm
dma.h
10725
0644
edit
dl
rm
drmem.h
2970
0644
edit
dl
rm
dtl.h
1515
0644
edit
dl
rm
dt_cpu_ftrs.h
756
0644
edit
dl
rm
edac.h
1105
0644
edit
dl
rm
eeh.h
15478
0644
edit
dl
rm
eeh_event.h
826
0644
edit
dl
rm
ehv_pic.h
963
0644
edit
dl
rm
elf.h
6283
0644
edit
dl
rm
elfnote.h
527
0644
edit
dl
rm
emergency-restart.h
43
0644
edit
dl
rm
emulated_ops.h
2072
0644
edit
dl
rm
epapr_hcalls.h
16827
0644
edit
dl
rm
exception-64e.h
5785
0644
edit
dl
rm
exception-64s.h
4350
0644
edit
dl
rm
exec.h
246
0644
edit
dl
rm
extable.h
1205
0644
edit
dl
rm
fadump-internal.h
4352
0644
edit
dl
rm
fadump.h
1095
0644
edit
dl
rm
fb.h
483
0644
edit
dl
rm
feature-fixups.h
9828
0644
edit
dl
rm
firmware.h
5327
0644
edit
dl
rm
fixmap.h
3723
0644
edit
dl
rm
floppy.h
5111
0644
edit
dl
rm
fsl_85xx_cache_sram.h
812
0644
edit
dl
rm
fsl_gtm.h
1203
0644
edit
dl
rm
fsl_hcalls.h
17615
0644
edit
dl
rm
fsl_lbc.h
10489
0644
edit
dl
rm
fsl_pamu_stash.h
411
0644
edit
dl
rm
fsl_pm.h
1183
0644
edit
dl
rm
fs_pd.h
1046
0644
edit
dl
rm
ftrace.h
3550
0644
edit
dl
rm
futex.h
2246
0644
edit
dl
rm
grackle.h
331
0644
edit
dl
rm
hardirq.h
948
0644
edit
dl
rm
head-64.h
5507
0644
edit
dl
rm
heathrow.h
2595
0644
edit
dl
rm
highmem.h
2079
0644
edit
dl
rm
hmi.h
971
0644
edit
dl
rm
hugetlb.h
2186
0644
edit
dl
rm
hvcall.h
21250
0644
edit
dl
rm
hvconsole.h
790
0644
edit
dl
rm
hvcserver.h
1473
0644
edit
dl
rm
hvsi.h
2850
0644
edit
dl
rm
hw_breakpoint.h
3735
0644
edit
dl
rm
hw_irq.h
11218
0644
edit
dl
rm
hydra.h
2948
0644
edit
dl
rm
i8259.h
361
0644
edit
dl
rm
ibmebus.h
2204
0644
edit
dl
rm
icswx.h
5090
0644
edit
dl
rm
ide.h
586
0644
edit
dl
rm
idle.h
2372
0644
edit
dl
rm
imc-pmu.h
3983
0644
edit
dl
rm
immap_cpm2.h
10749
0644
edit
dl
rm
inst.h
3683
0644
edit
dl
rm
interrupt.h
18353
0644
edit
dl
rm
io-defs.h
3164
0644
edit
dl
rm
io-workarounds.h
1313
0644
edit
dl
rm
io.h
31387
0644
edit
dl
rm
iommu.h
10283
0644
edit
dl
rm
io_event_irq.h
1746
0644
edit
dl
rm
ipic.h
3141
0644
edit
dl
rm
irq.h
1320
0644
edit
dl
rm
irqflags.h
1777
0644
edit
dl
rm
irq_work.h
213
0644
edit
dl
rm
isa-bridge.h
654
0644
edit
dl
rm
jump_label.h
1351
0644
edit
dl
rm
kasan.h
1396
0644
edit
dl
rm
Kbuild
286
0644
edit
dl
rm
kdebug.h
291
0644
edit
dl
rm
kdump.h
1399
0644
edit
dl
rm
kexec.h
4838
0644
edit
dl
rm
kexec_ranges.h
943
0644
edit
dl
rm
keylargo.h
11061
0644
edit
dl
rm
kfence.h
650
0644
edit
dl
rm
kgdb.h
2156
0644
edit
dl
rm
kprobes.h
2815
0644
edit
dl
rm
kup.h
3259
0644
edit
dl
rm
kvm_asm.h
4952
0644
edit
dl
rm
kvm_book3s.h
17220
0644
edit
dl
rm
kvm_book3s_32.h
816
0644
edit
dl
rm
kvm_book3s_64.h
18333
0644
edit
dl
rm
kvm_book3s_asm.h
3777
0644
edit
dl
rm
kvm_book3s_uvmem.h
2738
0644
edit
dl
rm
kvm_booke.h
2233
0644
edit
dl
rm
kvm_booke_hv_asm.h
1960
0644
edit
dl
rm
kvm_fpu.h
2199
0644
edit
dl
rm
kvm_guest.h
566
0644
edit
dl
rm
kvm_host.h
21966
0644
edit
dl
rm
kvm_para.h
752
0644
edit
dl
rm
kvm_ppc.h
36699
0644
edit
dl
rm
libata-portmap.h
249
0644
edit
dl
rm
linkage.h
501
0644
edit
dl
rm
livepatch.h
1140
0644
edit
dl
rm
local.h
3258
0644
edit
dl
rm
lppaca.h
5015
0644
edit
dl
rm
lv1call.h
18555
0644
edit
dl
rm
machdep.h
9630
0644
edit
dl
rm
macio.h
3985
0644
edit
dl
rm
mc146818rtc.h
736
0644
edit
dl
rm
mce.h
6396
0644
edit
dl
rm
mediabay.h
1375
0644
edit
dl
rm
membarrier.h
877
0644
edit
dl
rm
mem_encrypt.h
532
0644
edit
dl
rm
mman.h
1471
0644
edit
dl
rm
mmiowb.h
374
0644
edit
dl
rm
mmu.h
11244
0644
edit
dl
rm
mmu_context.h
9646
0644
edit
dl
rm
mmzone.h
1003
0644
edit
dl
rm
module.h
2284
0644
edit
dl
rm
module.lds.h
95
0644
edit
dl
rm
mpc5xxx.h
439
0644
edit
dl
rm
mpc6xx.h
143
0644
edit
dl
rm
mpc52xx.h
11100
0644
edit
dl
rm
mpc52xx_psc.h
10125
0644
edit
dl
rm
mpc85xx.h
2382
0644
edit
dl
rm
mpc5121.h
3863
0644
edit
dl
rm
mpc8260.h
742
0644
edit
dl
rm
mpic.h
14309
0644
edit
dl
rm
mpic_msgr.h
3441
0644
edit
dl
rm
mpic_timer.h
1183
0644
edit
dl
rm
msi_bitmap.h
867
0644
edit
dl
rm
nmi.h
579
0644
edit
dl
rm
nvram.h
2834
0644
edit
dl
rm
ohare.h
1684
0644
edit
dl
rm
opal-api.h
31680
0644
edit
dl
rm
opal.h
17843
0644
edit
dl
rm
paca.h
8783
0644
edit
dl
rm
page.h
10362
0644
edit
dl
rm
page_32.h
1626
0644
edit
dl
rm
page_64.h
2716
0644
edit
dl
rm
paravirt.h
3881
0644
edit
dl
rm
parport.h
956
0644
edit
dl
rm
pasemi_dma.h
23273
0644
edit
dl
rm
pci-bridge.h
9481
0644
edit
dl
rm
pci.h
3605
0644
edit
dl
rm
percpu.h
815
0644
edit
dl
rm
perf_event.h
1509
0644
edit
dl
rm
perf_event_fsl_emb.h
1252
0644
edit
dl
rm
perf_event_server.h
7104
0644
edit
dl
rm
pgalloc.h
2067
0644
edit
dl
rm
pgtable-be-types.h
2601
0644
edit
dl
rm
pgtable-types.h
1895
0644
edit
dl
rm
pgtable.h
4047
0644
edit
dl
rm
pkeys.h
4279
0644
edit
dl
rm
plpar_wrappers.h
10193
0644
edit
dl
rm
pmac_feature.h
13396
0644
edit
dl
rm
pmac_low_i2c.h
3100
0644
edit
dl
rm
pmac_pfunc.h
8237
0644
edit
dl
rm
pmc.h
1116
0644
edit
dl
rm
pmi.h
1177
0644
edit
dl
rm
pnv-ocxl.h
3069
0644
edit
dl
rm
pnv-pci.h
2432
0644
edit
dl
rm
powernv.h
454
0644
edit
dl
rm
ppc-opcode.h
31419
0644
edit
dl
rm
ppc-pci.h
2282
0644
edit
dl
rm
ppc4xx.h
328
0644
edit
dl
rm
ppc_asm.h
20530
0644
edit
dl
rm
probes.h
1542
0644
edit
dl
rm
processor.h
11898
0644
edit
dl
rm
prom.h
7324
0644
edit
dl
rm
ps3.h
15219
0644
edit
dl
rm
ps3av.h
23422
0644
edit
dl
rm
ps3gpu.h
1928
0644
edit
dl
rm
ps3stor.h
1408
0644
edit
dl
rm
pte-walk.h
2281
0644
edit
dl
rm
ptrace.h
10508
0644
edit
dl
rm
qspinlock.h
2064
0644
edit
dl
rm
qspinlock_paravirt.h
221
0644
edit
dl
rm
reg.h
64465
0644
edit
dl
rm
reg_8xx.h
2867
0644
edit
dl
rm
reg_a2.h
6128
0644
edit
dl
rm
reg_booke.h
33882
0644
edit
dl
rm
reg_fsl_emb.h
3961
0644
edit
dl
rm
rheap.h
2578
0644
edit
dl
rm
rio.h
424
0644
edit
dl
rm
rtas-types.h
2939
0644
edit
dl
rm
rtas.h
12574
0644
edit
dl
rm
runlatch.h
1184
0644
edit
dl
rm
seccomp.h
1043
0644
edit
dl
rm
sections.h
1982
0644
edit
dl
rm
secure_boot.h
476
0644
edit
dl
rm
security_features.h
3509
0644
edit
dl
rm
secvar.h
765
0644
edit
dl
rm
serial.h
473
0644
edit
dl
rm
setjmp.h
400
0644
edit
dl
rm
setup.h
2475
0644
edit
dl
rm
set_memory.h
1160
0644
edit
dl
rm
sfp-machine.h
12676
0644
edit
dl
rm
shmparam.h
206
0644
edit
dl
rm
signal.h
320
0644
edit
dl
rm
simple_spinlock.h
6662
0644
edit
dl
rm
simple_spinlock_types.h
481
0644
edit
dl
rm
slice.h
1121
0644
edit
dl
rm
smp.h
7804
0644
edit
dl
rm
smu.h
19789
0644
edit
dl
rm
sparsemem.h
843
0644
edit
dl
rm
spinlock.h
472
0644
edit
dl
rm
spinlock_types.h
382
0644
edit
dl
rm
spu.h
23963
0644
edit
dl
rm
spu_csa.h
6166
0644
edit
dl
rm
spu_info.h
272
0644
edit
dl
rm
spu_priv1.h
5186
0644
edit
dl
rm
sstep.h
4730
0644
edit
dl
rm
stackprotector.h
788
0644
edit
dl
rm
stacktrace.h
297
0644
edit
dl
rm
string.h
2522
0644
edit
dl
rm
svm.h
652
0644
edit
dl
rm
swab.h
173
0644
edit
dl
rm
swiotlb.h
374
0644
edit
dl
rm
switch_to.h
2966
0644
edit
dl
rm
synch.h
2067
0644
edit
dl
rm
syscall.h
3057
0644
edit
dl
rm
syscalls.h
2189
0644
edit
dl
rm
task_size_32.h
544
0644
edit
dl
rm
task_size_64.h
2390
0644
edit
dl
rm
tce.h
892
0644
edit
dl
rm
termios.h
653
0644
edit
dl
rm
thread_info.h
6166
0644
edit
dl
rm
time.h
2997
0644
edit
dl
rm
timex.h
463
0644
edit
dl
rm
tlb.h
2308
0644
edit
dl
rm
tlbflush.h
271
0644
edit
dl
rm
tm.h
624
0644
edit
dl
rm
topology.h
3536
0644
edit
dl
rm
trace.h
4695
0644
edit
dl
rm
trace_clock.h
372
0644
edit
dl
rm
tsi108.h
3264
0644
edit
dl
rm
tsi108_irq.h
3916
0644
edit
dl
rm
tsi108_pci.h
1191
0644
edit
dl
rm
types.h
822
0644
edit
dl
rm
uaccess.h
14288
0644
edit
dl
rm
udbg.h
2003
0644
edit
dl
rm
uic.h
403
0644
edit
dl
rm
ultravisor-api.h
941
0644
edit
dl
rm
ultravisor.h
2101
0644
edit
dl
rm
uninorth.h
8410
0644
edit
dl
rm
unistd.h
1445
0644
edit
dl
rm
uprobes.h
801
0644
edit
dl
rm
user.h
2192
0644
edit
dl
rm
vas.h
7580
0644
edit
dl
rm
vdso.h
1096
0644
edit
dl
rm
vdso_datapage.h
3570
0644
edit
dl
rm
vermagic.h
490
0644
edit
dl
rm
vga.h
1273
0644
edit
dl
rm
vio.h
4734
0644
edit
dl
rm
vmalloc.h
554
0644
edit
dl
rm
word-at-a-time.h
4878
0644
edit
dl
rm
xics.h
4539
0644
edit
dl
rm
xive-regs.h
5083
0644
edit
dl
rm
xive.h
5191
0644
edit
dl
rm
xmon.h
733
0644
edit
dl
rm
xor.h
1017
0644
edit
dl
rm
xor_altivec.h
683
0644
edit
dl
rm
Edit:
/usr/src/linux-headers-5.15.0-190/arch/powerpc/include/asm/fsl_lbc.h
(10489B)
/* SPDX-License-Identifier: GPL-2.0-or-later */ /* Freescale Local Bus Controller * * Copyright © 2006-2007, 2010 Freescale Semiconductor * * Authors: Nick Spence <nick.spence@freescale.com>, * Scott Wood <scottwood@freescale.com> * Jack Lan <jack.lan@freescale.com> */ #ifndef __ASM_FSL_LBC_H #define __ASM_FSL_LBC_H #include <linux/compiler.h> #include <linux/types.h> #include <linux/io.h> #include <linux/device.h> #include <linux/spinlock.h> struct fsl_lbc_bank { __be32 br; /**< Base Register */ #define BR_BA 0xFFFF8000 #define BR_BA_SHIFT 15 #define BR_PS 0x00001800 #define BR_PS_SHIFT 11 #define BR_PS_8 0x00000800 /* Port Size 8 bit */ #define BR_PS_16 0x00001000 /* Port Size 16 bit */ #define BR_PS_32 0x00001800 /* Port Size 32 bit */ #define BR_DECC 0x00000600 #define BR_DECC_SHIFT 9 #define BR_DECC_OFF 0x00000000 /* HW ECC checking and generation off */ #define BR_DECC_CHK 0x00000200 /* HW ECC checking on, generation off */ #define BR_DECC_CHK_GEN 0x00000400 /* HW ECC checking and generation on */ #define BR_WP 0x00000100 #define BR_WP_SHIFT 8 #define BR_MSEL 0x000000E0 #define BR_MSEL_SHIFT 5 #define BR_MS_GPCM 0x00000000 /* GPCM */ #define BR_MS_FCM 0x00000020 /* FCM */ #define BR_MS_SDRAM 0x00000060 /* SDRAM */ #define BR_MS_UPMA 0x00000080 /* UPMA */ #define BR_MS_UPMB 0x000000A0 /* UPMB */ #define BR_MS_UPMC 0x000000C0 /* UPMC */ #define BR_V 0x00000001 #define BR_V_SHIFT 0 #define BR_RES ~(BR_BA|BR_PS|BR_DECC|BR_WP|BR_MSEL|BR_V) __be32 or; /**< Base Register */ #define OR0 0x5004 #define OR1 0x500C #define OR2 0x5014 #define OR3 0x501C #define OR4 0x5024 #define OR5 0x502C #define OR6 0x5034 #define OR7 0x503C #define OR_FCM_AM 0xFFFF8000 #define OR_FCM_AM_SHIFT 15 #define OR_FCM_BCTLD 0x00001000 #define OR_FCM_BCTLD_SHIFT 12 #define OR_FCM_PGS 0x00000400 #define OR_FCM_PGS_SHIFT 10 #define OR_FCM_CSCT 0x00000200 #define OR_FCM_CSCT_SHIFT 9 #define OR_FCM_CST 0x00000100 #define OR_FCM_CST_SHIFT 8 #define OR_FCM_CHT 0x00000080 #define OR_FCM_CHT_SHIFT 7 #define OR_FCM_SCY 0x00000070 #define OR_FCM_SCY_SHIFT 4 #define OR_FCM_SCY_1 0x00000010 #define OR_FCM_SCY_2 0x00000020 #define OR_FCM_SCY_3 0x00000030 #define OR_FCM_SCY_4 0x00000040 #define OR_FCM_SCY_5 0x00000050 #define OR_FCM_SCY_6 0x00000060 #define OR_FCM_SCY_7 0x00000070 #define OR_FCM_RST 0x00000008 #define OR_FCM_RST_SHIFT 3 #define OR_FCM_TRLX 0x00000004 #define OR_FCM_TRLX_SHIFT 2 #define OR_FCM_EHTR 0x00000002 #define OR_FCM_EHTR_SHIFT 1 #define OR_GPCM_AM 0xFFFF8000 #define OR_GPCM_AM_SHIFT 15 }; struct fsl_lbc_regs { struct fsl_lbc_bank bank[12]; u8 res0[0x8]; __be32 mar; /**< UPM Address Register */ u8 res1[0x4]; __be32 mamr; /**< UPMA Mode Register */ #define MxMR_OP_NO (0 << 28) /**< normal operation */ #define MxMR_OP_WA (1 << 28) /**< write array */ #define MxMR_OP_RA (2 << 28) /**< read array */ #define MxMR_OP_RP (3 << 28) /**< run pattern */ #define MxMR_MAD 0x3f /**< machine address */ __be32 mbmr; /**< UPMB Mode Register */ __be32 mcmr; /**< UPMC Mode Register */ u8 res2[0x8]; __be32 mrtpr; /**< Memory Refresh Timer Prescaler Register */ __be32 mdr; /**< UPM Data Register */ u8 res3[0x4]; __be32 lsor; /**< Special Operation Initiation Register */ __be32 lsdmr; /**< SDRAM Mode Register */ u8 res4[0x8]; __be32 lurt; /**< UPM Refresh Timer */ __be32 lsrt; /**< SDRAM Refresh Timer */ u8 res5[0x8]; __be32 ltesr; /**< Transfer Error Status Register */ #define LTESR_BM 0x80000000 #define LTESR_FCT 0x40000000 #define LTESR_PAR 0x20000000 #define LTESR_WP 0x04000000 #define LTESR_ATMW 0x00800000 #define LTESR_ATMR 0x00400000 #define LTESR_CS 0x00080000 #define LTESR_UPM 0x00000002 #define LTESR_CC 0x00000001 #define LTESR_NAND_MASK (LTESR_FCT | LTESR_PAR | LTESR_CC) #define LTESR_MASK (LTESR_BM | LTESR_FCT | LTESR_PAR | LTESR_WP \ | LTESR_ATMW | LTESR_ATMR | LTESR_CS | LTESR_UPM \ | LTESR_CC) #define LTESR_CLEAR 0xFFFFFFFF #define LTECCR_CLEAR 0xFFFFFFFF #define LTESR_STATUS LTESR_MASK #define LTEIR_ENABLE LTESR_MASK #define LTEDR_ENABLE 0x00000000 __be32 ltedr; /**< Transfer Error Disable Register */ __be32 lteir; /**< Transfer Error Interrupt Register */ __be32 lteatr; /**< Transfer Error Attributes Register */ __be32 ltear; /**< Transfer Error Address Register */ __be32 lteccr; /**< Transfer Error ECC Register */ u8 res6[0x8]; __be32 lbcr; /**< Configuration Register */ #define LBCR_LDIS 0x80000000 #define LBCR_LDIS_SHIFT 31 #define LBCR_BCTLC 0x00C00000 #define LBCR_BCTLC_SHIFT 22 #define LBCR_AHD 0x00200000 #define LBCR_LPBSE 0x00020000 #define LBCR_LPBSE_SHIFT 17 #define LBCR_EPAR 0x00010000 #define LBCR_EPAR_SHIFT 16 #define LBCR_BMT 0x0000FF00 #define LBCR_BMT_SHIFT 8 #define LBCR_BMTPS 0x0000000F #define LBCR_BMTPS_SHIFT 0 #define LBCR_INIT 0x00040000 __be32 lcrr; /**< Clock Ratio Register */ #define LCRR_DBYP 0x80000000 #define LCRR_DBYP_SHIFT 31 #define LCRR_BUFCMDC 0x30000000 #define LCRR_BUFCMDC_SHIFT 28 #define LCRR_ECL 0x03000000 #define LCRR_ECL_SHIFT 24 #define LCRR_EADC 0x00030000 #define LCRR_EADC_SHIFT 16 #define LCRR_CLKDIV 0x0000000F #define LCRR_CLKDIV_SHIFT 0 u8 res7[0x8]; __be32 fmr; /**< Flash Mode Register */ #define FMR_CWTO 0x0000F000 #define FMR_CWTO_SHIFT 12 #define FMR_BOOT 0x00000800 #define FMR_ECCM 0x00000100 #define FMR_AL 0x00000030 #define FMR_AL_SHIFT 4 #define FMR_OP 0x00000003 #define FMR_OP_SHIFT 0 __be32 fir; /**< Flash Instruction Register */ #define FIR_OP0 0xF0000000 #define FIR_OP0_SHIFT 28 #define FIR_OP1 0x0F000000 #define FIR_OP1_SHIFT 24 #define FIR_OP2 0x00F00000 #define FIR_OP2_SHIFT 20 #define FIR_OP3 0x000F0000 #define FIR_OP3_SHIFT 16 #define FIR_OP4 0x0000F000 #define FIR_OP4_SHIFT 12 #define FIR_OP5 0x00000F00 #define FIR_OP5_SHIFT 8 #define FIR_OP6 0x000000F0 #define FIR_OP6_SHIFT 4 #define FIR_OP7 0x0000000F #define FIR_OP7_SHIFT 0 #define FIR_OP_NOP 0x0 /* No operation and end of sequence */ #define FIR_OP_CA 0x1 /* Issue current column address */ #define FIR_OP_PA 0x2 /* Issue current block+page address */ #define FIR_OP_UA 0x3 /* Issue user defined address */ #define FIR_OP_CM0 0x4 /* Issue command from FCR[CMD0] */ #define FIR_OP_CM1 0x5 /* Issue command from FCR[CMD1] */ #define FIR_OP_CM2 0x6 /* Issue command from FCR[CMD2] */ #define FIR_OP_CM3 0x7 /* Issue command from FCR[CMD3] */ #define FIR_OP_WB 0x8 /* Write FBCR bytes from FCM buffer */ #define FIR_OP_WS 0x9 /* Write 1 or 2 bytes from MDR[AS] */ #define FIR_OP_RB 0xA /* Read FBCR bytes to FCM buffer */ #define FIR_OP_RS 0xB /* Read 1 or 2 bytes to MDR[AS] */ #define FIR_OP_CW0 0xC /* Wait then issue FCR[CMD0] */ #define FIR_OP_CW1 0xD /* Wait then issue FCR[CMD1] */ #define FIR_OP_RBW 0xE /* Wait then read FBCR bytes */ #define FIR_OP_RSW 0xE /* Wait then read 1 or 2 bytes */ __be32 fcr; /**< Flash Command Register */ #define FCR_CMD0 0xFF000000 #define FCR_CMD0_SHIFT 24 #define FCR_CMD1 0x00FF0000 #define FCR_CMD1_SHIFT 16 #define FCR_CMD2 0x0000FF00 #define FCR_CMD2_SHIFT 8 #define FCR_CMD3 0x000000FF #define FCR_CMD3_SHIFT 0 __be32 fbar; /**< Flash Block Address Register */ #define FBAR_BLK 0x00FFFFFF __be32 fpar; /**< Flash Page Address Register */ #define FPAR_SP_PI 0x00007C00 #define FPAR_SP_PI_SHIFT 10 #define FPAR_SP_MS 0x00000200 #define FPAR_SP_CI 0x000001FF #define FPAR_SP_CI_SHIFT 0 #define FPAR_LP_PI 0x0003F000 #define FPAR_LP_PI_SHIFT 12 #define FPAR_LP_MS 0x00000800 #define FPAR_LP_CI 0x000007FF #define FPAR_LP_CI_SHIFT 0 __be32 fbcr; /**< Flash Byte Count Register */ #define FBCR_BC 0x00000FFF }; /* * FSL UPM routines */ struct fsl_upm { __be32 __iomem *mxmr; int width; }; extern u32 fsl_lbc_addr(phys_addr_t addr_base); extern int fsl_lbc_find(phys_addr_t addr_base); extern int fsl_upm_find(phys_addr_t addr_base, struct fsl_upm *upm); /** * fsl_upm_start_pattern - start UPM patterns execution * @upm: pointer to the fsl_upm structure obtained via fsl_upm_find * @pat_offset: UPM pattern offset for the command to be executed * * This routine programmes UPM so the next memory access that hits an UPM * will trigger pattern execution, starting at pat_offset. */ static inline void fsl_upm_start_pattern(struct fsl_upm *upm, u8 pat_offset) { clrsetbits_be32(upm->mxmr, MxMR_MAD, MxMR_OP_RP | pat_offset); } /** * fsl_upm_end_pattern - end UPM patterns execution * @upm: pointer to the fsl_upm structure obtained via fsl_upm_find * * This routine reverts UPM to normal operation mode. */ static inline void fsl_upm_end_pattern(struct fsl_upm *upm) { clrbits32(upm->mxmr, MxMR_OP_RP); while (in_be32(upm->mxmr) & MxMR_OP_RP) cpu_relax(); } /* overview of the fsl lbc controller */ struct fsl_lbc_ctrl { /* device info */ struct device *dev; struct fsl_lbc_regs __iomem *regs; int irq[2]; wait_queue_head_t irq_wait; spinlock_t lock; void *nand; /* status read from LTESR by irq handler */ unsigned int irq_status; #ifdef CONFIG_SUSPEND /* save regs when system go to deep-sleep */ struct fsl_lbc_regs *saved_regs; #endif }; extern int fsl_upm_run_pattern(struct fsl_upm *upm, void __iomem *io_base, u32 mar); extern struct fsl_lbc_ctrl *fsl_lbc_ctrl_dev; #endif /* __ASM_FSL_LBC_H */
Save
cmd:
run