Advertisement
Guest User

Untitled

a guest
Jun 1st, 2015
271
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.15 KB | None | 0 0
  1. component shift;
  2.  
  3.  
  4. pin in u32 length;
  5. pin out u32 dataout;
  6.  
  7.  
  8. option singleton;
  9. option extra_setup;
  10. option extra_cleanup;
  11.  
  12.  
  13. function write "Send data over rtnet";
  14.  
  15.  
  16. license "GPL";
  17. author "Klemen";
  18.  
  19. ;;
  20.  
  21. #include "rtapi_math.h"
  22.  
  23.  
  24. EXTRA_SETUP()
  25. {
  26.  
  27.  
  28.  
  29. u32 temp0, temp1;
  30.  
  31.  
  32.  
  33. temp0 = length;
  34. temp0 = temp0 >> 8;
  35. temp1 = length;
  36. temp1 = temp1 << 8;
  37. rtapi_print_msg(RTAPI_MSG_ERR,"ahift: %d >> %d << %d\n",length, temp0, temp1);
  38.  
  39.  
  40.  
  41. return 0;
  42. }
  43.  
  44.  
  45.  
  46. EXTRA_CLEANUP()
  47. {
  48.  
  49. }
  50.  
  51. FUNCTION(write)
  52. {
  53. dataout = 0x00112233;
  54.  
  55. }
  56.  
  57.  
  58. error:
  59. Jun 1 23:29:04 klemen-lucija1 kernel: [ 60.485227] RTAI[usi]: enabled.
  60. Jun 1 23:29:04 klemen-lucija1 kernel: [ 60.564597] RTAI[math]: loaded.
  61. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.026968] *pde = cda96067
  62. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.026987] Modules linked in: shift(+) siggen threads hal_lib rtapi rtai_math rtai_sem rtai_fifos rtai_sched rtai_hal binfmt_misc snd_hda_codec_realtek fbcon tileblit font bitblit softcursor vga16fb vgastate snd_hda_intel snd_hda_codec snd_hwdep snd_pcm_oss snd_mixer_oss snd_pcm snd_seq_dummy snd_seq_oss snd_seq_midi snd_rawmidi snd_seq_midi_event snd_seq joydev i915 drm_kms_helper snd_timer snd_seq_device ppdev pl2303 drm i2c_algo_bit snd parport_pc parport usbhid intel_agp video usbserial hid soundcore snd_page_alloc output agpgart 8139too 8139cp r8169 mii
  63. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027077]
  64. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027084] Pid: 1481, comm: insmod Not tainted (2.6.32-122-rtai #rtai)
  65. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027091] EIP: 0060:[<f863e072>] EFLAGS: 00010246 CPU: 0
  66. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027100] EIP is at init_module+0x4b/0x185 [shift]
  67. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027107] EAX: 00000000 EBX: f9bbf120 ECX: 00000000 EDX: f9bbf000
  68. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027114] ESI: f863e218 EDI: f9bbf12c EBP: f4a31f5c ESP: f4a31f10
  69. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027121] DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
  70. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027145] 00000000 f863e218 f4a31f28 00000001 00000000 c071e9c0 00000000 00000000
  71. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027163] <0> f4a31f38 c019b157 f4a31f54 c056c373 f863e218 00000001 c071d3b0 00000001
  72. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027183] <0> 3cff7263 fffffffc 00000000 f4a31f88 c0101041 f863e218 c071d3c0 fffffffc
  73. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027223] [<c019b157>] ? tracepoint_module_notify+0x27/0x30
  74. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027237] [<c056c373>] ? notifier_call_chain+0x43/0x60
  75. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027249] [<c0101041>] ? do_one_initcall+0x31/0x1b0
  76. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027260] [<f863e027>] ? init_module+0x0/0x185 [shift]
  77. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027273] [<c0179781>] ? sys_init_module+0xb1/0x220
  78. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027285] [<c010340d>] ? syscall_call+0x7/0xb
  79. Jun 1 23:29:13 klemen-lucija1 kernel: [ 70.027399] ---[ end trace 03917a607592a84a ]---
  80. klemen@klemen-lucija1:~$
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement