To bug is human, to debug is divine
via Quora

@theartofmadeline

★

gracie abrams

tannertan36
Misplaced Lens Cap
One Nice Bug Per Day
art blog(derogatory)

Origami Around

❣ Chile in a Photography ❣

Love Begins
trying on a metaphor
I'd rather be in outer space 🛸
2025 on Tumblr: Trends That Defined the Year
"I'm Dorothy Gale from Kansas"
NASA

if i look back, i am lost

#extradirty
Monterey Bay Aquarium
seen from United States

seen from Ecuador
seen from United States
seen from United States
seen from United States
seen from United States

seen from United States
seen from United States

seen from Mexico

seen from Malaysia

seen from United States

seen from Brazil

seen from Canada
seen from Italy
seen from United States

seen from United States

seen from Bangladesh

seen from Spain
seen from United States

seen from Malaysia
@krblogs
To bug is human, to debug is divine
via Quora

Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
Free to watch • No registration required • HD streaming
OpenCL for Android masses
It calls for an announcement. Pocl (POrtable Computing Language) has been ported to android Pocl is an opensource implementation of OpenCL 1.2 spec. It supports a range of cpu devices & custom processors. Now it runs on android ARMv7 cpus too
First things first Get pocl from playstore play.google.com/store/apps/details?id=org.pocl.libs Open this app once. It will install pocl files at a predefined place For a sanity check, run this pocl vector-addition sample play.google.com/store/apps/details?id=org.pocl.sample1
Features: 1. OpenCL 1.2 spec implementation 2. Provides a cpu device which uses pthread to utilise multi-core cpu 3. Zero-copy buffers when allocated with CL_MEM_USE_HOST_PTR flag 4. Programs & kernels are cached in application's cache directory at first run. Although initial launch will be slow, subsequent launches will be much much faster 5. Basic support for spir. Pocl now loads SPIR binaries via the clCreateProgramWithBinary. Even final binaries of spir will be cached at first run 6. Horizontal auto-vectorization of work-groups (experimental)
This is in beta stage and only android 4.2 and above is supported for now
clpeak - peak performance of your opencl device
As an opencl developer, we all want to know peak capabilities of our device. I have been working on a small repo on github github.com/krrishnarraj/clpeak to measure peak performance of opencl device
So what does it do? Measure peak bandwidth for all vector-widths of float. Measure single & double precision compute capacity for all vector-widths. Measure transfer bandwidth from host to device and kernel launch latency. A preview of cayman
Platform: AMD Accelerated Parallel Processing Device: Cayman Driver version: 1348.4 (Linux x64) Global memory bandwidth (GBPS) float : 130.97 float2 : 131.36 float4 : 90.50 float8 : 69.91 float16 : 35.27 Single-precision compute (GFLOPS) float : 674.44 float2 : 1345.68 float4 : 2601.47 float8 : 2586.69 float16 : 2573.38 Double-precision compute (GFLOPS) double : 671.24 double2 : 671.59 double4 : 670.93 double8 : 669.51 double16 : 666.50 Transfer bandwidth (GBPS) enqueueWriteBuffer : 3.53 enqueueReadBuffer : 4.43 enqueueMapBuffer(for read) : 152.89 memcpy from mapped ptr : 4.40 enqueueUnmap(after write) : 1781.26 memcpy to mapped ptr : 4.42 Kernel launch latency : 44.22 us
Highlights:
Mali drivers on chromebook
Now that arm has released linux drivers for graphics and opencl. Time for some experiments. Mali developer site has a dedicated page for samsung chromebook setup. Some steps can be ignored depending on your system setup. There are 2 versions of driver fbdev & x11. fbdev is a cpu based backend and x11 can use gpu based display backend. Userspace driver package contains drivers for egl, glesv2 and opencl
I used a basic test for display benchmark. The IE fishtank test fbdev backend: ~25 fps armsoc x11 backend: ~47 fps Looks like there is come gpu acceleration on graphics side
Coming to my favorite part. OpenCL. There are 2 versions of drivers, fbdev & armsoc. Not sure if that matters for opencl. libopencl.so has a linker dependency on libmali.so. Infact libmali.so contains all opencl symbolsI and libOpenCL.so is just a dummy stub library. I thought I can have pocl and mali drivers working together. Adding an icd entry for mali in /etc/OpenCL/vendors didn't work. All the precompiled cl utilities like clinfo complained that some symbols are missing when loaded against mali opencl library, probably because it was compiled against 1.2 and mali provides opencl 1.1. Now that pocl and mali can't co-exist, I deleted pocl
So to use mali driver, copy libmali.so & libmali_cinstr_plugin.so to /usr/lib. This itself is opencl library. Create shortlinks
OpenCL on arm linux
OpenCL on ARM looks very exciting. New architecture, new set of optimizations. I managed to get 2 opencl platforms working on arm chromebook
Number of platforms: 2 Platform Name: Portable Computing Language Platform Vendor: The pocl project Platform Version: OpenCL 1.2 pocl 0.9-pre Platform Profile: FULL_PROFILE Platform Extensions: cl_khr_icd
Platform Name: coprthr Platform Vendor: Brown Deer Technology, LLC. Platform Version: coprthr-1.6-CURRENT (Freewill) Platform Profile: <profile> Platform Extensions: cl_khr_icd
I purchased this samsung chromebook thinking that I can work on the first arm opencl capable Mali gpu. Much to my sorrow, there are no gpu drivers for linux yet. They provided only android opencl drivers for arndale board. So wont this android driver work on linux if android is nothing but linux?? NO. Android uses a different libc library called bionic. All these drivers are compiled for bionic and not libc!!

Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
Free to watch • No registration required • HD streaming
Bootloader unlock on samsung arm chromebook
Well one more post on chromebook. This chromebook is so secure that its really difficult to break its boot sequence and take control of the bootloader. http://www.chromium.org/chromium-os/developer-information-for-chrome-os-devices/custom-firmware explains the sequence. Some people might have been frustrated with that mandatory key press in developer mode. Archlinux guys have found a way to flash nv-uboot(non verified uboot) to spi firmware. This way you get a grub like interface to boot kernel of your wish.
Courtesy http://archlinuxarm.org/forum/viewtopic.php?f=27&t=4016&hilit=protect&start=80#p29341 post in arch forum.
SPI is read-only by default. You can open the chromebook and remove a sticker in the motherboard which makes SPI read-write Steps:
0. Take a backup of all important data. Anything can go wrong. Have a bootable external mmc ready in case if anything goes wrong
1. Open backcover of chromebook. Follow instructions from ifixit http://www.ifixit.com/Teardown/Samsung+Chromebook+11.6+Teardown/12225/2#s45950
THE samsung arm chromebook
So what is cool about this laptop. Everything. Its the first commercial ARM laptop for just $250. It is the top selling laptop on amazon http://hothardware.com/News/Samsung-Chromebook-Now-Top-Selling-Laptop-on-Amazon/ and is still in on top as of now http://www.amazon.com/Best-Sellers-Electronics-Laptop-Computers/zgbs/electronics/565108/
Coming to specs, it sports exynos 5250 dual core ARM A15 cpus with mali T604 gpu. 11.6" screen with 16 GB SSD. There are no heat sink fans because the soc hardly drains 5W at full speed which makes it even lite
Sad part is that its not available here in India. Since I badly wanted to own this device I got via ebay. It comes with chromium os which is decent enough for browsing. Lot of enthusiasts out there are trying to get a stable linux distro for this device so that they can have a complete development setup. Here are the few projects
1. Crouton: Most popular for its ease of use https://github.com/dnschneid/crouton Its creates a chroot environment on top of chrome os. It doesn't give you a complete linux experience
2. Marcin Juszkiewicz was working at Canonical. His most popular post http://marcin.juszkiewicz.com.pl/2013/02/14/how-to-install-ubuntu-13-04-on-chromebook/ explained how to get ubuntu on chromebook. Now that he has left Canonical, he doesn't expect much support from ubuntu community for this device
Airtel 4G LTE on Linux
I recently purchased airtel 4G internet for its reasonable cost and high speed. You get a constant download speed of 10 Mbps here in b'lor. My problem with this usb device was I couldn't get this working on linux! Yes, they did provide software setup for windows/linux, all those were x86 based. I have this ARM chromebook and who will provide that piece of software with connect and disconnect button!
The modem is basically from ZTE, ZTE MF825A. The documentation provided by zte is (in)dispensable for the fact that this product is not listed anywhere in their website. If you provide a good looking GUI with connect/disconnect button and not say how it works, how can it satisfy a linux guy
Ok. So this is what happens. When you connect the device it is detected as usb storage device. Then udev kicks in and mode switches it to 1408 from 1225. cdc_ether module picks up this device and creates an ethernet connection. Check the below dmesg log
[ 104.025283] usb 2-1: new high-speed USB device number 4 using s5p-ehci [ 104.183421] usb 2-1: New USB device found, idVendor=19d2, idProduct=1225 [ 104.183498] usb 2-1: New USB device strings: Mfr=2, Product=3, SerialNumber=4 [ 104.183562] usb 2-1: Product: ZTE WCDMA Technologies MSM [ 104.183616] usb 2-1: Manufacturer: ZTE,Incorporated [ 104.183667] usb 2-1: SerialNumber: MF8250ZTED000000 [ 104.327876] usbcore: registered new interface driver libusual [ 104.380155] Initializing USB Mass Storage driver... [ 104.383780] scsi0 : usb-storage 2-1:1.0 [ 104.388458] usbcore: registered new interface driver usb-storage [ 104.388518] USB Mass Storage support registered. [ 105.395342] scsi 0:0:0:0: CD-ROM CWID USB SCSI CD-ROM 2.31 PQ: 0 ANSI: 2 [ 105.407270] scsi 0:0:0:1: Direct-Access ZTE MMC Storage 2.31 PQ: 0 ANSI: 2 [ 105.463160] sd 0:0:0:1: [sda] Attached SCSI removable disk [ 105.553641] sr0: scsi-1 drive [ 105.553668] cdrom: Uniform CD-ROM driver Revision: 3.20 [ 105.554806] sr 0:0:0:0: Attached scsi CD-ROM sr0 [ 110.415922] usb 2-1: USB disconnect, device number 4 [ 110.790178] usb 2-1: new high-speed USB device number 5 using s5p-ehci [ 110.948539] usb 2-1: New USB device found, idVendor=19d2, idProduct=1408 [ 110.948614] usb 2-1: New USB device strings: Mfr=2, Product=3, SerialNumber=4 [ 110.948677] usb 2-1: Product: ZTE WCDMA Technologies MSM [ 110.948730] usb 2-1: Manufacturer: ZTE,Incorporated [ 110.948780] usb 2-1: SerialNumber: MF8250ZTED000000 [ 110.976822] scsi1 : usb-storage 2-1:1.2 [ 111.139335] cdc_ether 2-1:1.0: eth0: register 'cdc_ether' at usb-s5p-ehci-1, CDC Ethernet Device, 34:4b:50:b6:ab:3c [ 111.141926] usbcore: registered new interface driver cdc_ether
and ifconfig
eth0 Link encap:Ethernet HWaddr 34:4b:50:b6:ab:3c inet addr:192.168.0.144 Bcast:192.168.0.255 Mask:255.255.255.0 ..........................................................................
Although an internal ip is assigned, there is no internet at this point. What surprised me was how can usb modem get an ethernet connection? how? I went to linux, ubuntu forums, no help! I assumed that kernel wrongly detected this device. I forced QMI module to load driver for this device by editing the kernel. Although it loaded the qmi driver, /dev/cdc-wdm0 was not usable. Finally I contacted Bjorn(author of qmi-wwan.c in linux tree). After looking at the logs, he told that this device is probably not a qmi device. He asked me to check with cdc_ether connection and open gateway ip(192.168.0.1) in the browser. "Page not found"!
My last resort was to go to a linux x86 m/c and trace what that connect/disconnect 'GUI' was doing using wireshark. Take it. So simple. Connect button called http://192.168.0.1/goform/goform_set_cmd_process using post method with goformId="CONNECT_NETWORK" as parameter. Thats all and you are connected to internet. Here is a small html snippet that imitates the GUI
<form action = "http://192.168.0.1/goform/goform_set_cmd_process" method = "post"> <input type="checkbox" name="goformId" value="CONNECT_NETWORK" checked style="display:none;"> <BUTTON name="submit" type="submit"> Connect </BUTTON> </form>
<form action = "http://192.168.0.1/goform/goform_set_cmd_process" method = "post"> <input type="checkbox" name="goformId" value="DISCONNECT_NETWORK" checked style="display:none;"> <BUTTON name="submit" type="submit"> Disconnect </BUTTON> </form>
The green led blinks after connecting to internet
Above html snippet can be downloaded from https://drive.google.com/file/d/0ByAtbw9O9wYyc2JCbzVwa2RZNTQ/edit?usp=sharing
Update 1:
Good news. This method works on android too. I just received my new Moto G and it works
First turn off edge/hspa/wifi, or in simple terms no ip is assigned to the system. Connect the dongle to phone using an OTG cable. Wait for sometime until red led turns green. This means kernel has detected the device. Goto settings->About->Status and check ip address. If 192.168.0.144/192.168.0.145 ip is assined you are good to go. Restart once if you don't get the ip.
Download above html page and open it in chrome (default html viewer doesn't work) file:///sdcard/path/to/html/file and connect
4G internet on a 3G phone :)
Problem is with the first part !!
Hello World
And finally my long awaited blog is finally up. Ah what a relief. I had so many things running on my mind(ya, technical) which I wanted to share. Many experiments have gone undocumented
So what am I upto? Basically am a OpenCL guy, huge fan, and recently opencl and gpgpu stuffs on ARM mobiles. Most of my posts will be based on this. And ofcourse THE samsung chromebook - "The first ARM laptop in the world". The very nature of it being an ARM laptop is exciting. Well posts on this will surely come. Apart from opencl, am a huge fan of linux too
So here starts my blog. Thank you for reading

Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
Free to watch • No registration required • HD streaming