Saturday, December 10, 2011

Kernel: Linux / Windows

- Monolithic Kernel vs Micro Kernel
http://www.vmars.tuwien.ac.at/courses/akti12/journal/04ss/article_04ss_Roch.pdf
http://en.wikipedia.org/wiki/Kernel_(computing)
http://linuxhelp.blogspot.com/2006/05/monolithic-kernel-vs-microkernel-which.html

- Korean
http://blog.naver.com/PostView.nhn?blogId=sdc4697&logNo=140103690630&redirect=Dlog&widgetTypeCall=true
http://recipes.egloos.com/5365126
http://itislord.tistory.com/tag/%EB%AA%A8%EB%86%80%EB%A6%AC%EB%94%95%20%EC%BB%A4%EB%84%90%28Monolithic%29

- Windows
http://www.driveronline.org/bbs/view.asp?tb=systembbs&GotoPage=1&s_bulu=&s_key=&no=24
http://keon.egloos.com/5202360
http://www.osnews.com/story/22501/Microsoft_Kernel_Engineers_Talk_About_Windows_7_s_Kernel

- Kernel comparision Linux vs Windows
http://widefox.pbworks.com/w/page/8042308/Kernel%20Comparison%20Linux%20vs%20Windows
http://widefox.pbworks.com/w/page/8042290/Architecture

http://jnux.tistory.com/entry/%EC%8A%A4%ED%81%AC%EB%9E%A9-%EB%AA%A8%EB%B0%94%EC%9D%BC-%ED%94%8C%EB%9E%AB%ED%8F%BC%EA%B3%BC-%EB%AA%A8%EB%B0%94%EC%9D%BC-OS%EC%9D%98-%EC%B0%A8%EC%9D%B4

http://www.google.com/search?sourceid=chrome&ie=UTF-8&q=%EC%9C%88%EB%8F%84%EC%9A%B0+%EC%BB%A4%EB%84%90%EA%B3%BC+%EB%A6%AC%EB%88%85%EC%8A%A4+%EC%BB%A4%EB%84%90%EC%9D%98+%EC%B0%A8%EC%9D%B4

OneNand, iNand, and MobiNand

Korean
http://search.naver.com/search.naver?where=nexearch&query=%EC%95%84%EC%9D%B4%EB%82%B8%EB%93%9C+%EB%AA%A8%EB%B9%84%EB%82%B8%EB%93%9C&x=0&y=0&sm=top_hty&fbm=0&ie=utf8
http://gall.dcinside.com/list.php?id=smartphone&no=1437467

1. MLC (Multi Level Cell) / SLC (Single Level Cell)
http://www.navinside.com/bbs/zboard.php?id=forum_istation&no=3359
1.1 MLC type: MoviNand and iNand (same type)
1.2 SLC type: OneNand

2.1 Diff. between MoviNand and iNand
http://people.sarang.net/?document_srl=1104294

http://blog.naver.com/PostView.nhn?blogId=mercurian21&logNo=30047740523

자양이네 (ps3, 타블렛, 리눅스, 안드로이드)

갤럭시s의 oneNAND, moviNAND의 포맷및 파티션 변경
http://blog.naver.com/dowkim10?Redirect=Log&logNo=120119813742
갤럭시 s의 파티션 및 파일 시스템 (rfs/ext2/ext3/ext4)
http://blog.naver.com/dowkim10?Redirect=Log&logNo=120119813742
Samsung Galaxy S Series
http://forum.xda-developers.com/wiki/index.php?title=Samsung_Galaxy_S_Series

RFS
http://www.samsung.com/global/business/semiconductor/products/fusionmemory/Products_RFS_Brochure.html
http://movitool.ntd.homelinux.org/trac/movitool/wiki/RFS

http://www.samsungmomentforum.com/samsung-moment-rooting/bml151617-yaffs2!/

In the Linux, build error logging

    3.6.4 Redirecting Standard Output and Standard Error

    This construct allows both the standard output (file descriptor 1) and the standard error output (file descriptor 2) to be redirected to the file whose name is the expansion of word.
    There are two formats for redirecting standard output and standard error:
    &>word
    and
    >&word
    Of the two forms, the first is preferred. This is semantically equivalent to
    >word 2>&1

    case #1
    # make flag 2&> build.log
    case #2
    # make flag > build.log 2>&1

      C language, Tips

      1. Maximal munch rule (최대한 잘라먹기 규칙)
      x+++++y is
      ((x++)++) + y

      2. Floating Point Arithmetic (부동 소수점 연산)
      David Goldberg, "What Every Computer Scientist Should Know About Floating-Point Arithmetic," March 1991, ACM Computing Surveys, Vol. 21, No. 1
      IEEE 754
      IEEE 854

      3. Declaration specifier (선언 지정자)
      선언 지정자에 나열되는 순서는 상관이 없음
      그러나 아래와 같은 방법을 추천함
      기억부류 지정자 형한정어 형지정자
      static const volatile char

      #define MY_DEFINE 0

      void main(void)
      {
      #if defined(MY_DEFINE)
      printf("Yes, defined.\r\n");
      #else
      printf("No, undefined.\r\n");
      #endif // MY_DEFINE
      }

      output> Yes, defined.

      Saturday, August 20, 2011

      Enabling XDMCP in Ubuntu 11.04

      XDMCP is X Display Manager Control Protocol

      1. install xdm
      (If you installed xdm before, pass this step)
      #apt-get install xdm

      2. Edit /etc/gdm/custom.conf as follow: (If custom.conf is not exist, make it)
      #vim /etc/dgm/custom.conf

      [daemon]
      User=gdm
      Group=gdm

      [security]
      DisallowTCP=true

      [xdmcp]
      Enable=true
      DisplaysPerHost=2
      HonorIndirect=false
      MaxPending=4
      MaxSessions=16
      MaxWait=30
      MaxWaitIndirect=30
      PingIntervalSeconds=60
      Port=177

      [greeter]

      [chooser]
      Multicast=false

      [debug]
      Enable=false

      Calling Convention

      X86 calling conventions

      Argument Passing and Naming Conventions (C++)

      - The following calling conventions are supported by the Visual C/C++ compiler.
      1. cdecl: stack cleanup (caller), parameter passing (stack, right to left)
      2. stdcall: stack cleanup (callee), parameter passing (stack, right to left)
      3. fastcall: stack cleanup (callee), parameter passing (stored in register, then pushed on stack)

      Video Tutorial - Calling Conventions

      Tuesday, August 16, 2011

      Linux: likely & unlikely

      In the Linux,
      You can see the below code

      if ( likely(x == 0) )
      {
      // code ...
      }
      or
      if ( unlikely(x == 1) )
      {
      // code ...
      }

      #define likely(x) __builtin_expect((x),1)
      #define unlikely(x) __builtin_expect((x),0)


      As I know, its another expression is "Branch Prediction".
      It is supported gcc 2.96 or later version.

      likely/unlikely macros in the Linux kernel
      http://stackoverflow.com/questions/109710/likely-unlikely-macros-in-the-linux-kernel

      Kernel : likely/unlikely macros
      http://kerneltrap.org/node/4705

      Wednesday, August 3, 2011

      Tuesday, July 26, 2011

      Sunday, July 10, 2011

      Linux: Current Frequency

      How to read cpu frequency on android device
      http://stackoverflow.com/questions/3021054/how-to-read-cpu-frequency-on-android-device

      How to detect android cpu speed?
      http://stackoverflow.com/questions/4875415/how-to-detect-android-cpu-speed


      Linux: CPU scaling governor

      Governors In the Linux Kernel
      1 Performance
      2 Powersave
      3 Userspace
      4 Ondemand
      5 Conservative
      6 Interactive
      7 InteractiveX

      http://bonsai.googlecode.com/svn-history/r447/trunk/kernel-src/linux-2.6.32.9/Documentation/cpu-freq/governors.txt

      http://icarus21.tistory.com/entry/CPU-Frequency-Governor


      # cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

      For all available scaling governors:
      # cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors

      Check Available frequencies
      # cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies

      To control CPU1 manually,
      # echo 0 > /sys/devices/system/cpu/cpu1/online
      # echo 1 > /sys/devices/system/cpu/cpu1/online


      Update 6/28 2013
      =============================================
      CPU Governors
      http://forum.xda-developers.com/showthread.php?t=1736168

      Linux: DVFS & hotplug

      Web:
      - Linux kernel CPU Frequency 변경(DVFS) 코드


      PDF:

      Saturday, June 11, 2011

      How to debug in Release Mode in Visual C++ 6.0

      Project > Setting > C/C++ tab menu
      Debug Info: change from None to Program database

      And, Project > Setting > Link
      Check, Generate debug info