|
rk3288使用GPIO作为中断口发生中断时产生大量奇怪log,并且设置双边沿中断时只能触...
发表于 2016-5-4 20:45:25
浏览:6728
|
回复:1
打印
只看该作者
[复制链接]
楼主
我使用gpio8 A7作为中断口,设置双边沿中断,代码如下:
[mw_shl_code=c,false] my_ultrasonic_device.ultrasonic_gpio_echo = ULTRASONIC_GPIO_ECHO;
gpio_request(my_ultrasonic_device.ultrasonic_gpio_echo,"ultrasonic echo gpio.");
gpio_direction_input(my_ultrasonic_device.ultrasonic_gpio_echo);
request_irq(gpio_to_irq(my_ultrasonic_device.ultrasonic_gpio_echo),ultrasonic_irq_handle,IRQF_TRIGGER_RISING|IRQF_TRIGGER_FALLING , "ultrasonic_irq", &my_ultrasonic_device);
[/mw_shl_code]
当有波形产生时,会产生大量log,然后只能产生一次中断。
[mw_shl_code=shell,false]shell@firefly:/sys/devices/eareye_ultrasonic_device.20 #
shell@firefly:/sys/devices/eareye_ultrasonic_device.20 # echo 1 > Ultrasonic
shell@firefly:/sys/devices/eareye_ultrasonic_device.20 # [ 68.509527] irq event 192: bogus return value c362f
[ 68.509582] [wzy] time:0,800303.
[ 68.509756] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.10.0 #173
[ 68.509919] [<c0013ec4>] (unwind_backtrace+0x0/0xe0) from [<c001176c>] (show_stack+0x10/0x14)
[ 68.510058] [<c001176c>] (show_stack+0x10/0x14) from [<c009f6f8>] (__report_bad_irq+0x28/0xb8)
[ 68.510195] [<c009f6f8>] (__report_bad_irq+0x28/0xb8) from [<c009dc58>] (handle_irq_event_percpu+0x25c/0x28c)
[ 68.510325] [<c009dc58>] (handle_irq_event_percpu+0x25c/0x28c) from [<c009dcc4>] (handle_irq_event+0x3c/0x5c)
[ 68.510453] [<c009dcc4>] (handle_irq_event+0x3c/0x5c) from [<c00a04c0>] (handle_edge_irq+0x114/0x14c)
[ 68.510580] [<c00a04c0>] (handle_edge_irq+0x114/0x14c) from [<c009d498>] (generic_handle_irq+0x20/0x30)
[ 68.510705] [<c009d498>] (generic_handle_irq+0x20/0x30) from [<c029841c>] (rockchip_irq_demux+0x130/0x228)
[ 68.510828] [<c029841c>] (rockchip_irq_demux+0x130/0x228) from [<c009d498>] (generic_handle_irq+0x20/0x30)
[ 68.510956] [<c009d498>] (generic_handle_irq+0x20/0x30) from [<c000e3cc>] (handle_IRQ+0x64/0x8c)
[ 68.511076] [<c000e3cc>] (handle_IRQ+0x64/0x8c) from [<c000853c>] (gic_handle_irq+0x38/0x5c)
[ 68.511191] [<c000853c>] (gic_handle_irq+0x38/0x5c) from [<c000d600>] (__irq_svc+0x40/0x70)
[ 68.511271] Exception stack(0xc0bedf08 to 0xc0bedf50)
[ 68.511366] df00: c0bedf50 00000044 17fb74b3 00000010 c1ef92e0 00000000
[ 68.511476] df20: 17f65b09 00000010 c0bfefd8 c0bec000 c0bfefe8 00000000 132a9479 c0bedf50
[ 68.511565] df40: c0079850 c05adce8 60030013 ffffffff
[ 68.511692] [<c000d600>] (__irq_svc+0x40/0x70) from [<c05adce8>] (cpuidle_enter_state+0x54/0xec)
[ 68.511829] [<c05adce8>] (cpuidle_enter_state+0x54/0xec) from [<c05adeec>] (cpuidle_idle_call+0x16c/0x27c)
[ 68.511961] [<c05adeec>] (cpuidle_idle_call+0x16c/0x27c) from [<c000e750>] (arch_cpu_idle+0x8/0x38)
[ 68.512091] [<c000e750>] (arch_cpu_idle+0x8/0x38) from [<c0078c14>] (cpu_idle_loop+0x1b8/0x224)
[ 68.512215] [<c0078c14>] (cpu_idle_loop+0x1b8/0x224) from [<c0078c8c>] (freezing_slow_path+0x0/0x80)
[ 68.512331] [<c0078c8c>] (freezing_slow_path+0x0/0x80) from [<ffffffff>] (0xffffffff)
[ 68.512401] handlers:
[ 68.512483] [<c0320fe4>] ultrasonic_irq_handle
shell@firefly:/sys/devices/eareye_ultrasonic_device.20 #
[/mw_shl_code]
请问这个问题该如何解决?
|
|