用的100ask tina5.0开发环境。按照这个帖子配置的G2D。
https://bbs.aw-ol.com/topic/4086/t113-s3-%E9%A9%B1%E5%8A%A8%E5%B1%8F%E5%B9%95%E6%98%BE%E7%A4%BA%E9%97%AE%E9%A2%98
openwrt环境,测试gstreamer sunxifbsink组件出现异常。大虾们能帮我看看,问题可能在哪?测试命令和异常日志如下:
root@TinaLinux:/# gst-launch-1.0 videotestsrc ! sunxifbsink
divx class init!
mjpeg class init!
-->sunxifbsink init.
Setting pipeline to PAUSED ...
dd: error writing '/dev/fb0': No space left on device
[ 132.495401] VE: enable hw clock
6406+0 records in
6405+0 records out
[ 132.502556] enable_cedar_hw_clk,563
Succesfully opened fbdev framebuffer device /dev/fb0, mapped sized 12.00 MB of which 10.95 MB (7 buffers) usable for page flippi[ 132.524014] 8<--- cut here ---
ng.
fbdev phy=0x00000000,len=0x320a00,vir=0xb5c89000,size=0xc00000.
-->/dev/transform does not exist, hardware rotation [ 132.528973] Unable to handle kernel paging request at virtual address ebebebc0
is not supported.
-->reserver layer called (screen = 480 x 854).
-->Hardware overlay available.
Succesfully opened screen[ 132.548127] pgd = 5db4edc1
of pixel depth 32, dimensions 480 x 854, format BGRx, 12.00 MB video memory available, max 7 pannable screen buffers, vsync ena[ 132.562229] [ebebebc0] *pgd=00000000
bled.
Pipeline is PREROLLING ...
---->sunxifb pre overlay(SCWxSCN=320 x 240,out_rec=[80 307,320,240]).
Using one framebuffer [ 132.577311] Internal error: Oops: 2805 [#1] PREEMPT SMP ARM
plus 8 overlays in video memory (format YV12).
[ 132.594611] Modules linked in:
[ 132.602178] CPU: 1 PID: 2195 Comm: videotestsrc0:s Not tainted 5.4.61 #1
[ 132.609643] Hardware name: Generic DT based system
[ 132.614991] PC is at b15_dma_flush_range+0x1c/0x34
[ 132.620335] LR is at compat_cedardev_ioctl+0xc28/0xdb4
[ 132.626058] pc : [<c0114d00>] lr : [<c0593b78>] psr: 60030013
[ 132.633041] sp : c59f3ed0 ip : 00000010 fp : 0018dcd0
[ 132.638861] r10: 00000036 r9 : c59f2000 r8 : c59f2000
[ 132.644682] r7 : c5964700 r6 : 00000506 r5 : c59f2000 r4 : b5c87568
[ 132.651956] r3 : 0000003f r2 : 00000040 r1 : ebedadeb r0 : ebebebc0
[ 132.659230] Flags: nZCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment none
[ 132.667181] Control: 10c5387d Table: 459ac06a DAC: 00000051
[ 132.673583] Process videotestsrc0:s (pid: 2195, stack limit = 0xd0e007f5)
[ 132.681148] Stack: (0xc59f3ed0 to 0xc59f4000)
[ 132.686002] 3ec0: ebebebeb 00000000 ebedadeb 00000000
[ 132.695121] 3ee0: b5e35000 5150fb9a c59aed78 b5c87568 c5a0c038 c5964700 00000506 c59f2000
[ 132.704237] 3f00: c59f2000 c01ed19c b5c87568 c01edf50 00000000 00000000 00000000 00000000
[ 132.713356] 3f20: b5345000 5150fb9a 00200070 c59f3fb0 00000055 b5e35000 c5a99e40 c014fe14
[ 132.722474] 3f40: c59f3fb0 00000055 b5e35000 c010f320 c5964700 00000001 00004000 c6b46100
[ 132.731591] 3f60: 00000006 5150fb9a 00000036 00000006 c5964701 c5964700 00000506 b5c87568
[ 132.740707] 3f80: c59f2000 00000036 0018dcd0 c01ee02c b689cf10 ebebebeb ebebebeb 00000036
[ 132.749824] 3fa0: c0101228 c0101000 b689cf10 ebebebeb 00000006 00000506 b5c87568 000cb910
[ 132.758943] 3fc0: b689cf10 ebebebeb ebebebeb 00000036 000cff78 0018dcd0 b68edf34 0018dcd0
[ 132.768061] 3fe0: b689cf3c b5c87564 b688aa20 b6b2a92c 20030010 00000006 00000000 00000000
[ 132.777187] [<c0114d00>] (b15_dma_flush_range) from [<c0593b78>] (compat_cedardev_ioctl+0xc28/0xdb4)
[ 132.787376] [<c0593b78>] (compat_cedardev_ioctl) from [<c01ed19c>] (vfs_ioctl+0x18/0x3c)
[ 132.796400] [<c01ed19c>] (vfs_ioctl) from [<c01edf50>] (do_vfs_ioctl+0x620/0x6c8)
[ 132.804746] [<c01edf50>] (do_vfs_ioctl) from [<c01ee02c>] (ksys_ioctl+0x34/0x5c)
[ 132.812994] [<c01ee02c>] (ksys_ioctl) from [<c0101000>] (ret_fast_syscall+0x0/0x54)
[ 132.821527] Exception stack(0xc59f3fa8 to 0xc59f3ff0)
[ 132.827157] 3fa0: b689cf10 ebebebeb 00000006 00000506 b5c87568 000cb910
[ 132.836273] 3fc0: b689cf10 ebebebeb ebebebeb 00000036 000cff78 0018dcd0 b68edf34 0018dcd0
[ 132.845388] 3fe0: b689cf3c b5c87564 b688aa20 b6b2a92c
[ 132.851019] Code: e3a02004 e1a02312 e2423001 e1c00003 (ee070f3e)
[ 132.857811] ---[ end trace 56fe497e048d5b88 ]---
内核配置文件内容(为节约空间,删除了usb部分的设置):
# CONFIG_LOCALVERSION_AUTO is not set
CONFIG_SYSVIPC=y
CONFIG_NO_HZ=y
CONFIG_HIGH_RES_TIMERS=y
CONFIG_PREEMPT=y
CONFIG_BSD_PROCESS_ACCT=y
CONFIG_BSD_PROCESS_ACCT_V3=y
CONFIG_IKCONFIG=y
CONFIG_IKCONFIG_PROC=y
CONFIG_LOG_BUF_SHIFT=16
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
# CONFIG_SYSFS_SYSCALL is not set
CONFIG_KALLSYMS_ALL=y
CONFIG_EMBEDDED=y
# CONFIG_PERF_EVENTS is not set
# CONFIG_COMPAT_BRK is not set
CONFIG_PROFILING=y
CONFIG_ARCH_SUNXI=y
# CONFIG_MACH_SUN4I is not set
# CONFIG_MACH_SUN5I is not set
# CONFIG_MACH_SUN6I is not set
# CONFIG_MACH_SUN7I is not set
# CONFIG_MACH_SUN8I is not set
# CONFIG_MACH_SUN9I is not set
CONFIG_ARCH_SUN8IW20=y
CONFIG_EVB_PLATFORM=y
CONFIG_SUNXI_SOC_NAME="sun8iw20"
# CONFIG_VDSO is not set
CONFIG_SMP=y
CONFIG_SCHED_MC=y
CONFIG_NR_CPUS=2
CONFIG_ARM_PSCI=y
CONFIG_OABI_COMPAT=y
CONFIG_HIGHMEM=y
# CONFIG_ARM_MODULE_PLTS is not set
# CONFIG_ATAGS is not set
CONFIG_CMDLINE="loglevel=8 initcall_debug=1 console=ttyS0 init=/init"
CONFIG_CPU_FREQ=y
CONFIG_CPU_FREQ_STAT=y
CONFIG_CPU_FREQ_TIMES=y
CONFIG_CPU_FREQ_GOV_POWERSAVE=y
CONFIG_CPU_FREQ_GOV_USERSPACE=y
CONFIG_CPU_FREQ_GOV_ONDEMAND=y
CONFIG_CPU_FREQ_GOV_CONSERVATIVE=y
CONFIG_CPU_FREQ_GOV_SCHEDUTIL=y
CONFIG_CPUFREQ_DT=y
CONFIG_ARM_ALLWINNER_SUN50I_CPUFREQ_NVMEM=y
CONFIG_VFP=y
CONFIG_NEON=y
CONFIG_PM_WAKELOCKS=y
CONFIG_PM_DEBUG=y
CONFIG_PM_ADVANCED_DEBUG=y
CONFIG_JUMP_LABEL=y
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
# CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set
# CONFIG_COMPACTION is not set
CONFIG_CMA=y
CONFIG_NET=y
CONFIG_PACKET=y
CONFIG_UNIX=y
CONFIG_UNIX_DIAG=y
CONFIG_NET_KEY=y
CONFIG_INET=y
CONFIG_IP_MULTICAST=y
CONFIG_IP_ADVANCED_ROUTER=y
CONFIG_IP_FIB_TRIE_STATS=y
CONFIG_IP_MULTIPLE_TABLES=y
CONFIG_INET_IPCOMP=y
CONFIG_INET_UDP_DIAG=y
CONFIG_IPV6_TUNNEL=y
CONFIG_NETLINK_DIAG=y
CONFIG_CAN=y
CONFIG_BT=y
CONFIG_BT_RFCOMM=y
CONFIG_BT_RFCOMM_TTY=y
CONFIG_BT_HCIUART=y
CONFIG_BT_HCIUART_H4=y
CONFIG_XR_BT_LPM=y
CONFIG_CFG80211=y
CONFIG_RFKILL=y
CONFIG_RFKILL_GPIO=y
CONFIG_UEVENT_HELPER=y
CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
CONFIG_DEVTMPFS=y
CONFIG_DEVTMPFS_MOUNT=y
CONFIG_SUNXI_MBUS=y
CONFIG_MTD=y
CONFIG_MTD_SUNXI_PARTS=y
CONFIG_MTD_CHAR=y
CONFIG_MTD_BLOCK=y
CONFIG_MTD_SPI_NAND=y
CONFIG_AW_MTD_SPINAND=y
CONFIG_MTD_SPI_NOR=y
CONFIG_MTD_UBI_BLOCK=y
CONFIG_SUNXI_RFKILL=y
CONFIG_SUNXI_ADDR_MGT=y
CONFIG_SUNXI_BOOTEVENT=y
CONFIG_SCSI=y
CONFIG_BLK_DEV_SD=y
CONFIG_NETDEVICES=y
CONFIG_SUNXI_GMAC=y
CONFIG_USB_USBNET=y
CONFIG_XR829_WLAN=m
CONFIG_INPUT_EVDEV=y
CONFIG_INPUT_SENSORINIT=y
CONFIG_KEYBOARD_SUNXI=y
# CONFIG_INPUT_MOUSE is not set
CONFIG_INPUT_TOUCHSCREEN=y
CONFIG_TOUCHSCREEN_SUNXI=y
# CONFIG_TOUCHSCREEN_GSLX680NEW is not set
CONFIG_TOUCHSCREEN_GT9XXNEW_TS=m
CONFIG_INPUT_SENSOR=y
# CONFIG_LEGACY_PTYS is not set
CONFIG_DEVKMEM=y
# CONFIG_HW_RANDOM is not set
CONFIG_SUNXI_G2D=y
CONFIG_SUNXI_G2D_MIXER=y
CONFIG_SUNXI_G2D_ROTATE=y
CONFIG_SUNXI_DI=y
CONFIG_SUNXI_DI_V1XX=y
CONFIG_SUNXI_SYS_INFO=y
CONFIG_SUNXI_SMC=y
CONFIG_I2C=y
CONFIG_I2C_CHARDEV=y
CONFIG_I2C_SUNXI=y
CONFIG_SPI=y
CONFIG_SPI_SUNXI=y
CONFIG_SPI_SPIDEV=y
CONFIG_PINCTRL_SUNXI_DEBUGFS=y
CONFIG_DEBUG_GPIO=y
CONFIG_GPIO_SYSFS=y
CONFIG_GPIO_SUNXI=y
CONFIG_POWER_SUPPLY=y
CONFIG_THERMAL=y
CONFIG_THERMAL_DEFAULT_GOV_POWER_ALLOCATOR=y
CONFIG_THERMAL_GOV_STEP_WISE=y
CONFIG_THERMAL_GOV_USER_SPACE=y
CONFIG_THERMAL_GOV_POWER_ALLOCATOR=y
CONFIG_CPU_THERMAL=y
CONFIG_THERMAL_EMULATION=y
CONFIG_SUNXI_THERMAL=y
CONFIG_WATCHDOG=y
CONFIG_SUNXI_WATCHDOG=y
CONFIG_MFD_SUN6I_PRCM=y
CONFIG_REGULATOR=y
CONFIG_REGULATOR_FIXED_VOLTAGE=y
CONFIG_SUNXI_REGULATOR_PWM=y
CONFIG_RC_CORE=y
CONFIG_RC_DECODERS=y
CONFIG_IR_NEC_DECODER=y
CONFIG_IR_RC5_DECODER=y
CONFIG_RC_DEVICES=y
CONFIG_IR_RX_SUNXI=y
CONFIG_MEDIA_SUPPORT=y
CONFIG_MEDIA_CAMERA_SUPPORT=y
CONFIG_MEDIA_CONTROLLER=y
CONFIG_VIDEO_V4L2_SUBDEV_API=y
CONFIG_MEDIA_USB_SUPPORT=y
CONFIG_USB_VIDEO_CLASS=y
CONFIG_USB_GSPCA=y
CONFIG_V4L_PLATFORM_DRIVERS=y
CONFIG_VIDEO_SUNXI_TVD=y
CONFIG_SUNXI_PLATFORM_DRIVERS=y
CONFIG_VIDEO_SUNXI_VIN=y
CONFIG_CSI_VIN=y
# CONFIG_CSI_CCI is not set
CONFIG_SENSOR_N5_DVP=y
CONFIG_FB=y
CONFIG_DISP2_SUNXI=y
CONFIG_SUNXI_DISP2_FB_HW_ROTATION_SUPPORT=y
CONFIG_DISP2_SUNXI_DEBUG=y
# CONFIG_DISP2_SUNXI_DEVICE_OFF_ON_RELEASE is not set
CONFIG_SOUND=y
CONFIG_SND=y
CONFIG_SND_SOC=y
CONFIG_SND_SUNXI_SOC_SUN8IW20_CODEC=y
CONFIG_SND_SUNXI_SOC_SIMPLE_CARD=y
CONFIG_SND_SUNXI_SOC_DAUDIO=y
CONFIG_MMC=y
CONFIG_MMC_SUNXI=y
CONFIG_NEW_LEDS=y
CONFIG_LEDS_CLASS=y
CONFIG_LEDS_GPIO=y
CONFIG_LEDS_TRIGGERS=y
CONFIG_LEDS_TRIGGER_TIMER=y
CONFIG_LEDS_TRIGGER_ONESHOT=y
CONFIG_LEDS_TRIGGER_MTD=y
CONFIG_LEDS_TRIGGER_HEARTBEAT=y
CONFIG_LEDS_TRIGGER_BACKLIGHT=y
CONFIG_LEDS_TRIGGER_CPU=y
CONFIG_LEDS_TRIGGER_ACTIVITY=y
CONFIG_LEDS_TRIGGER_GPIO=y
CONFIG_LEDS_TRIGGER_DEFAULT_ON=y
CONFIG_RTC_CLASS=y
CONFIG_RTC_DRV_DS1302=y
CONFIG_DMADEVICES=y
CONFIG_DMA_SUN6I=y
CONFIG_STAGING=y
CONFIG_ION=y
CONFIG_ION_SYSTEM_HEAP=y
CONFIG_ION_CMA_HEAP=y
CONFIG_EXFAT_FS=y
CONFIG_EXFAT_DELAYED_SYNC=y
CONFIG_EXFAT_KERNEL_DEBUG=y
CONFIG_EXFAT_DEBUG_MSG=y
# CONFIG_COMMON_CLK_DEBUG is not set
# CONFIG_CLK_SUNXI_CLOCKS is not set
# CONFIG_CLK_SUNXI_DDR is not set
# CONFIG_CLK_SUNXI_PRCM_SUN6I is not set
# CONFIG_CLK_SUNXI_PRCM_SUN8I is not set
# CONFIG_CLK_SUNXI_PRCM_SUN9I is not set
# CONFIG_ARM_ARCH_TIMER_EVTSTREAM is not set
CONFIG_SUNXI_MAILBOX=y
CONFIG_SUNXI_IOMMU=y
CONFIG_SUNXI_IOMMU_DEBUG=y
CONFIG_SUNXI_IOMMU_TESTS=y
CONFIG_REMOTEPROC=y
CONFIG_SUNXI_REMOTEPROC=y
CONFIG_SUNXI_REMOTEPROC_HIFI4_BOOT=y
CONFIG_SUNXI_REMOTEPROC_C906_BOOT=y
CONFIG_RPMSG_VIRTIO=y
CONFIG_RPMSG_CTRL=y
CONFIG_RPBUF_SERVICE_RPMSG=y
CONFIG_RPBUF_CONTROLLER_SUNXI=y
# CONFIG_SUNXI_SRAM is not set
CONFIG_SUNXI_PM_DOMAINS=y
CONFIG_SUNXI_SID=y
CONFIG_PWM=y
CONFIG_PWM_SUNXI_GROUP=y
CONFIG_ANDROID=y
CONFIG_NVMEM_SUNXI_SID=y
CONFIG_EXT4_FS=y
CONFIG_EXT4_FS_POSIX_ACL=y
CONFIG_EXT4_FS_SECURITY=y
CONFIG_EXT4_DEBUG=y
# CONFIG_DNOTIFY is not set
CONFIG_FUSE_FS=y
CONFIG_CUSE=y
CONFIG_VIRTIO_FS=y
CONFIG_OVERLAY_FS=y
CONFIG_MSDOS_FS=y
CONFIG_VFAT_FS=y
CONFIG_FAT_DEFAULT_UTF8=y
CONFIG_NTFS_FS=y
CONFIG_NTFS_RW=y
CONFIG_TMPFS=y
CONFIG_TMPFS_POSIX_ACL=y
CONFIG_UBIFS_FS=y
CONFIG_UBIFS_FS_ADVANCED_COMPR=y
# CONFIG_UBIFS_FS_ZLIB is not set
# CONFIG_UBIFS_FS_ZSTD is not set
CONFIG_SQUASHFS=y
CONFIG_SQUASHFS_XZ=y
CONFIG_NLS_CODEPAGE_437=y
CONFIG_NLS_ISO8859_1=y
CONFIG_CRYPTO_ARC4=y
CONFIG_CRYPTO_DES=y
CONFIG_CRYPTO_ZSTD=y
CONFIG_CRYPTO_USER_API_HASH=y
CONFIG_CRYPTO_USER_API_SKCIPHER=y
CONFIG_CRYPTO_USER_API_RNG=y
CONFIG_CRYPTO_USER_API_AEAD=y
CONFIG_CRYPTO_DEV_SUNXI=m
CONFIG_DMA_CMA=y
CONFIG_PRINTK_TIME=y
CONFIG_DEBUG_INFO=y
CONFIG_FRAME_WARN=2048
CONFIG_DEBUG_FS=y
CONFIG_MAGIC_SYSRQ=y
CONFIG_DEBUG_VM=y
# CONFIG_SCHED_DEBUG is not set
CONFIG_DEBUG_MUTEXES=y
CONFIG_STACKTRACE=y
# CONFIG_FTRACE is not set
CONFIG_ATOMIC64_SELFTEST=y
CONFIG_DEBUG_LL=y
CONFIG_DEBUG_UART_PHYS=0x02500c00
CONFIG_DEBUG_UART_VIRT=0xf2500c00
CONFIG_EARLY_PRINTK=y
最近编辑记录 wuyu (2024-10-23 11:33:14)
离线
今天测试了一下,fbdev2sink组件也有问题。
root@TinaLinux:/# GST_DEBUG=3 gst-launch-1.0 videotestsrc ! fbdev2sink
divx class init!
0:00:00.781325584 2157 0x20f45a0 ERROR omx gstomx.c:4036:plugin_init: Invalid type name 'GstOMXVP8Dec' for element 'omxvp8videodec'
0:00:00.781992209 2157 0x20f45a0 ERROR omx gstomx.c:4036:plugin_init: Invalid type name 'GstOMXH265Dec' for element 'omxhevcvideodec'
mjpeg class init!
0:00:01.428525959 2156 0x1a959c0 WARN GST_REGISTRY gstregistry.c:1841:gst_update_registry: registry update failed: Error writing registry cache to /root/.cache/gstreamer-1.0/registry.arm.bin: No such file or d[ 19.492522] VE: enable hw clock
irectory
Setting pipeline to PAUSED ...
[ 19.499475] enable_cedar_hw_clk,563
Succesfully opened fbdev framebuffer device /dev/fb0, mapped sized 12.00 MB of which 10.95 MB (7 buffers) usable for page flipping.
fbdev phy=0x00000000,len=0x320a00,vir=0xb5c35000,size=0xc00000.
Succesfully opened screen of pixel depth 32, dimensions 480 x 854, format BGRx, 12.00 MB video memory available, max 7 pannable screen buffers, vsync enabled.
Pipeline is PREROLLING ...
0:00:01.476811043 2156 0x19e28b8 FIXME default gstutils.c:3981:gst_pad_create_stream_id_internal:<videotestsrc0:src> Creating random stream-id, consider implementing a deterministic way of creating a stream-id
Using 3 framebuffers for page flipping.
Allocating 3 screen buffers.
Pipeline is PREROLLED ...
Setting pipeline to[ 19.581106] L2 PageTable Invalid
[ 19.590243] 0x321000 is not mapped!
[ 19.594130] DE invalid address: 0x321000, data:0x0, id:0x4
PLAYING ...
New clock: GstSystemClock
[ 19.601317] L2 PageTable Invalid
[ 19.607440] 0x321000 is not mapped!
[ 19.611348] DE invalid address: 0x321000, data:0x0, id:0x4
[ 19.682155] L2 PageTable Invalid
[ 19.685766] 0x321000 is not mapped!
[ 19.689654] DE invalid address: 0x321000, data:0x0, id:0x4
[ 19.702361] L2 PageTable Invalid
[ 19.705970] 0x321000 is not mapped!
[ 19.709878] DE invalid address: 0x321000, data:0x0, id:0x4
^Chandling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:31.326661723
Setting pipeline to NULL ...
942 frames rendered, 942 from system memory, 0 from video memory.[ 50.886824] VE: disable hw clock
[ 50.895704] disable_cedar_hw_clk,603
Freeing pipeline ...
离线
由错误日志
L2 PageTable Invalid
[ 19.590243] 0x321000 is not mapped!
[ 19.594130] DE invalid address: 0x321000, data:0x0, id:0x4
跟踪到了sunxi-iommu.c文件当中的
static irqreturn_t sunxi_iommu_irq(int irq, void *dev_id)
{
u32 inter_status_reg = 0;
u32 addr_reg = 0;
u32 int_masterid_bitmap = 0;
u32 data_reg = 0;
u32 l1_pgint_reg = 0;
u32 l2_pgint_reg = 0;
u32 master_id = 0;
unsigned long mflag;
struct sunxi_iommu_dev *iommu = dev_id;
spin_lock_irqsave(&iommu->iommu_lock, mflag);
inter_status_reg = sunxi_iommu_read(iommu, IOMMU_INT_STA_REG) & 0x3ffff;
l1_pgint_reg = sunxi_iommu_read(iommu, IOMMU_L1PG_INT_REG);
l2_pgint_reg = sunxi_iommu_read(iommu, IOMMU_L2PG_INT_REG);
int_masterid_bitmap = inter_status_reg | l1_pgint_reg | l2_pgint_reg;
if (inter_status_reg & MICRO_TLB0_INVALID_INTER_MASK) {
pr_err("%s Invalid Authority\n", master[0]);
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG0);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG0);
} else if (inter_status_reg & MICRO_TLB1_INVALID_INTER_MASK) {
pr_err("%s Invalid Authority\n", master[1]);
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG1);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG1);
} else if (inter_status_reg & MICRO_TLB2_INVALID_INTER_MASK) {
pr_err("%s Invalid Authority\n", master[2]);
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG2);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG2);
} else if (inter_status_reg & MICRO_TLB3_INVALID_INTER_MASK) {
pr_err("%s Invalid Authority\n", master[3]);
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG3);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG3);
} else if (inter_status_reg & MICRO_TLB4_INVALID_INTER_MASK) {
pr_err("%s Invalid Authority\n", master[4]);
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG4);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG4);
} else if (inter_status_reg & MICRO_TLB5_INVALID_INTER_MASK) {
pr_err("%s Invalid Authority\n", master[5]);
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG5);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG5);
}
#if IS_ENABLED(CONFIG_ARCH_SUN8IW15) || IS_ENABLED(CONFIG_ARCH_SUN50IW9) \
|| IS_ENABLED(CONFIG_ARCH_SUN8IW19) || IS_ENABLED(CONFIG_ARCH_SUN50IW10) \
|| IS_ENABLED(CONFIG_ARCH_SUN8IW20) || IS_ENABLED(CONFIG_ARCH_SUN50IW12) \
|| IS_ENABLED(CONFIG_ARCH_SUN20IW1) || IS_ENABLED(CONFIG_ARCH_SUN55IW3)
else if (inter_status_reg & MICRO_TLB6_INVALID_INTER_MASK) {
pr_err("%s Invalid Authority\n", master[6]);
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG6);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG6);
} else if (inter_status_reg & L1_PAGETABLE_INVALID_INTER_MASK) {
/*It's OK to prefetch an invalid pagetable,no need to print msg for debug.*/
if (!(int_masterid_bitmap & (1U << 31)))
pr_err("L1 PageTable Invalid\n");
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG7);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG7);
} else if (inter_status_reg & L2_PAGETABLE_INVALID_INTER_MASK) {
if (!(int_masterid_bitmap & (1U << 31)))
pr_err("L2 PageTable Invalid\n");
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG8);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG8);
}
#else
else if (inter_status_reg & L1_PAGETABLE_INVALID_INTER_MASK) {
pr_err("L1 PageTable Invalid\n");
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG6);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG6);
} else if (inter_status_reg & L2_PAGETABLE_INVALID_INTER_MASK) {
pr_err("L2 PageTable Invalid\n");
addr_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_ADDR_REG7);
data_reg = sunxi_iommu_read(iommu, IOMMU_INT_ERR_DATA_REG7);
}
#endif
else
pr_err("sunxi iommu int error!!!\n");
if (!(int_masterid_bitmap & (1U << 31))) {
if (sunxi_iova_invalid_helper(addr_reg)) {
int_masterid_bitmap &= 0xffff;
master_id = __ffs(int_masterid_bitmap);
}
pr_err("%s invalid address: 0x%x, data:0x%x, id:0x%x\n",
master[master_id], addr_reg, data_reg,
int_masterid_bitmap);
}
#if IS_ENABLED(CONFIG_ARCH_SUN8IW19) || IS_ENABLED(CONFIG_ARCH_SUN50IW9) \
|| IS_ENABLED(CONFIG_ARCH_SUN50IW10)
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_START_ADDR_REG, addr_reg);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_END_ADDR_REG, addr_reg + 4 * SPAGE_SIZE);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_TLB_IVLD_ENABLE_REG) & 0x1)
;
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ADDR_REG, addr_reg);
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_PC_IVLD_ENABLE_REG) & 0x1)
;
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ADDR_REG,
addr_reg + 0x200000);
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_PC_IVLD_ENABLE_REG) & 0x1)
;
#elif IS_ENABLED(CONFIG_ARCH_SUN8IW20) || IS_ENABLED(CONFIG_ARCH_SUN50IW12) \
|| IS_ENABLED(CONFIG_ARCH_SUN20IW1) || IS_ENABLED(CONFIG_ARCH_SUN55IW3)
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_START_ADDR_REG, addr_reg);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_END_ADDR_REG, addr_reg + 4 * SPAGE_SIZE);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_TLB_IVLD_ENABLE_REG) & 0x1)
;
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_START_ADDR_REG, addr_reg);
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_END_ADDR_REG, addr_reg + 2 * SPD_SIZE);
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_PC_IVLD_ENABLE_REG) & 0x1)
;
#else
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ADDR_REG, addr_reg);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ADDR_MASK_REG,
(u32)IOMMU_PT_MASK);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_TLB_IVLD_ENABLE_REG) & 0x1)
;
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ADDR_REG,
addr_reg + 0x2000);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ADDR_MASK_REG,
(u32)IOMMU_PT_MASK);
sunxi_iommu_write(iommu, IOMMU_TLB_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_TLB_IVLD_ENABLE_REG) & 0x1)
;
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ADDR_REG, addr_reg);
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_PC_IVLD_ENABLE_REG) & 0x1)
;
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ADDR_REG,
addr_reg + 0x200000);
sunxi_iommu_write(iommu, IOMMU_PC_IVLD_ENABLE_REG, 0x1);
while (sunxi_iommu_read(iommu, IOMMU_PC_IVLD_ENABLE_REG) & 0x1)
;
#endif
sunxi_iommu_write(iommu, IOMMU_INT_CLR_REG, inter_status_reg);
inter_status_reg |= (l1_pgint_reg | l2_pgint_reg);
inter_status_reg &= 0xffff;
sunxi_iommu_write(iommu, IOMMU_RESET_REG, ~inter_status_reg);
sunxi_iommu_write(iommu, IOMMU_RESET_REG, 0xffffffff);
spin_unlock_irqrestore(&iommu->iommu_lock, mflag);
return IRQ_HANDLED;
}
感觉内存还没有映射好。也就是初始化的问题。
最近编辑记录 wuyu (2024-10-25 15:49:49)
离线
同样的环境,用fbdevsink组件测试是成功的。
root@(none):/# GST_DEBUG=3 gst-launch-1.0 videotestsrc ! fbdevsink
divx class init!
0:00:00.783731584 1403 0x1802460 ERROR omx gstomx.c:4036:plugin_init: Invalid type name 'GstOMXVP8Dec' for element 'omxvp8videodec'
0:00:00.784432667 1403 0x1802460 ERROR omx gstomx.c:4036:plugin_init: Invalid type name 'GstOMXH265Dec' for element 'omxhevcvideodec'
mjpeg class init!
0:00:01.166389251 1403 0x1802460 WARN GST_PLUGIN_LOADING gstplugin.c:793:_priv_gst_plugin_load_file_for_registry: module_open failed: /usr/lib/gstreamer-1.0/libgstvideo4linux2.so: undefined symbol: gst_v4l2_buffer_pool_resurect_buffer
(gst-plugin-scanner:1403): GStreamer-WARNING **: 15:17:25.634: Failed to load plugin '/usr/lib/gstreamer-1.0/libgstvideo4linux2.so': /usr/lib/gstreamer-1.0/libgstvideo4linux2.so: undefined symbol: gst_v4l2_buffer_pool_resurect_buffer
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
0:00:01.552186584 1402 0x1cb2880 FIXME default gstutils.c:3981:gst_pad_create_stream_id_internal:<videotestsrc0:src> Creating random stream-id, consider implementing a deterministic way of creating a stream-id
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
离线