Linux randomly not rebooting correctly

Dear Sir,

I`m having problem with system rebooting. After typing the command: reboot, linux quite often freeze, and only hard reset helps to start system correctly. It happens randomly. Bellow you can find full log from system rebooting:

The Angstrom Distribution apalis-t30 ttyS0

Angstrom v2015.12 - Kernel 3.1.10-g34c5824-dirty

Apalis_T30_LinuxImageV2.6_20160701

apalis-t30 login: [   18.012529] CPU1: shutdown
roo[   20.013937] CPU2: shutdown
t
Last login: Thu Oct  6 15:55:17 UTC 2016 on ttyS0
root@apalis-t30:~# reboot
[  OK  ] Removed slice system-getty.slice.
         Stopping Hostname Service...
         Unmounting /run/user/0...
[  OK  ] Stopped target Graphical Interface.
         Stopping Session c1 of user root.
[  OK  ] Stopped target Slices.
[  OK  ] Stopped target Sound Card.
         Stopping Disk Manager (legacy version)...
         Stopping Session c2 of user root.
[  OK  ] Stopped target Timers.
         Starting Store Sound Card State...
         Stopping Load/Save Random Seed...
[  OK  ] Stopped target System Time Synchronized.
         Stopping Network Time Synchronization...
         Stopping Load/Save Screen Bac[   24.163603] CPU1: Booted secondary processor
klight Brightness of backlight:pwm-backlight...
         Unmounting /media/mmcblk1p1...
[   24.180841] Switched to NOHz mode on CPU #1
         Stopping WPA supplicant...
         Stopping LXDE Display Manager...
[   24.211330] CPU2: Booted secondary processor
[   24.220835] Switched to NOHz mode on CPU #2
[  OK  ] Stopped Setup Virtual Console.
         Stopping Update UTMP about System Boot/Shutdown...
[  OK  ] Stopped target Paths.
[   24.311326] CPU3: Booted secondary processor
[   24.320836] Switched to NOHz mode on CPU #3
[  OK  ] Stopped Dispatch Password Requests to Console Directory Watch.
[  OK  ] Stopped target Sockets.
[  OK  ] Closed RPCbind Server Activation Socket.
[  OK  ] Stopped Daily Cleanup of Temporary Directories.
         Unmounting /media/mmcblk0p1...
         Stopping Timestamping service...
[  OK  ] Stopped target Multi-User System.
[  OK  ] Stopped target Login Prompts.
         Stopping Serial Getty on ttyS0...
         Stopping Avahi mDNS/DNS-SD Stack...
         Stopping Authorization Manager...
         Stopping Network Name Resolution...
[   24.597743] tegradc tegradc.0: switching framebuffer to 800x480
[   24.597763] tegradc tegradc.0: Calculated sync href=0 vref=1
[   24.597783] tegradc tegradc.0: using mode 800x480 pclk=32460000 href=0 vref=1
[  OK  ] Stopped Forward Password Requests to Wall Directory Watch.
[  OK  ] Stopped Network Time Synchronization.
[  OK  ] Stopped Avahi mDNS/DNS-SD Stack.
[  OK  ] Stopped Network Name Resolution.
[  OK  ] Stopped Hostname Service.
[  OK  ] Stopped WPA supplicant.
[  OK  ] Stopped LXDE Display Manager.
[  OK  ] Stopped Serial Getty on ttyS0.
[  OK  ] Stopped Authorization Manager.
[  OK  ] Stopped Disk Manager (legacy version).
[   26.344302] CPU1: shutdown
[  OK  ] Unmounted /run/user/0.
[  OK  ] Stopped Session c1 of user root.
[  OK  ] Stopped Session c2 of user root.
[  OK  ] Started Store Sound Card State.
[  OK  ] Stopped Load/Save Random Seed.
[  OK  ] Stopped Load/Save Screen Backlight ...ness of backlight:pwm-backlight.
[  OK  ] Unmounted /media/mmcblk1p1.
[  OK  ] Stopped Update UTMP about System Boot/Shutdown.
[  OK  ] Unmounted /media/mmcblk0p1.
[   28.314568] CPU2: shutdown
[  OK  ] Stopped Timestamping service.
[  OK  ] Removed slice system-systemd\x2dbacklight.slice.
[  OK  ] Removed slice user-0.slice.
         Stopping Login Service...
[  OK  ] Reached target Unmount All Filesystems.
[  OK  ] Stopped target Local File Systems (Pre).
[  OK  ] Stopped Create Static Device Nodes in /dev.
[  OK  ] Removed slice system-serial\x2dgetty.slice.
         Stopping Permit User Sessions...
[  OK  ] Stopped target Network.
         Stopping Network Service...
[  OK  ] Closed Avahi mDNS/DNS-SD Stack Activation Socket.
[  OK  ] Stopped Remount Root and Kernel File Systems.
[  OK  ] Stopped Create Volatile Files and Directories.
[  OK  ] Stopped Login Service.
[  OK  ] Stopped Network Service.
[  OK  ] Stopped Permit User Sessions.
[  OK  ] Stopped target Remote File Systems.
[  OK  ] Stopped target Remote File Systems (Pre).
         Stopping Connection service...
[  OK  ] Stopped Apply Kernel Variables.
[  OK  ] Removed slice User and Session Slice.
[   30.314043] CPU3: shutdown
[  OK  ] Stopped Connection service.
         Stopping D-Bus System Message Bus...
[  OK  ] Stopped D-Bus System Message Bus.
[  OK  ] Closed D-Bus System Message Bus Socket.
[  OK  ] Reached target Shutdown.
[   30.900629] systemd-shutdown[1]: Sending SIGTERM to remaining processes...
[   30.943582] systemd-journald[118]: Received SIGTERM from PID 1 (systemd-shutdow).
[   31.122132] systemd-shutdown[1]: Sending SIGKILL to remaining processes...
[   31.211138] systemd-shutdown[1]: Unmounting file systems.
[   31.217495] systemd-shutdown[1]: Unmounting /var/volatile.
[   31.240939] systemd-shutdown[1]: Unmounting /tmp.

The kernel tag shows -dirty. What exactly are the changes to the kernel? Can you share the diff of the kernel source please to rule out any doubtful changes.