title: Partition's size in df -h is totally different than the size in /proc/partitions
body: <p>I'm using buildroot to build a custom linux system for my raspi A+.</p>
  
  <p>Using genimage, I've created two partitions on a <strong>1 GB sdcard</strong>. The first partion is the boot partition. It's vfat and it is <strong>32 MB</strong>. The second partition is ext4, it is the rootfs and it is <strong>512 MB</strong>.</p>
  
  <p>Once I boot my raspi with the newly burned sdcard and that I type <code>df -h</code> I get this in the output:</p>
  
  <pre><code>Filesystem                Size      Used Available Use% Mounted on
  /dev/root                17.1M     14.0M      1.8M  89% /
  devtmpfs                200.6M         0    200.6M   0% /dev
  tmpfs                   200.7M         0    200.7M   0% /dev/shm
  tmpfs                   200.7M         0    200.7M   0% /tmp
  tmpfs                   200.7M      4.0K    200.7M   0% /run
  </code></pre>
  
  <p>as you can see, <code>/dev/root</code> is 17.1 MB instead of 512 MB.</p>
  
  <p>Then, I issue <code>cat /proc/partitions</code>:</p>
  
  <pre><code>major minor  #blocks  name
  
    1        0       4096 ram0
    1        1       4096 ram1
    1        2       4096 ram2
    1        3       4096 ram3
    1        4       4096 ram4
    1        5       4096 ram5
    1        6       4096 ram6
    1        7       4096 ram7
    1        8       4096 ram8
    1        9       4096 ram9
    1       10       4096 ram10
    1       11       4096 ram11
    1       12       4096 ram12
    1       13       4096 ram13
    1       14       4096 ram14
    1       15       4096 ram15
  179        0     969728 mmcblk0
  179        1      32768 mmcblk0p1
  179        2     524288 mmcblk0p2
  </code></pre>
  
  <p>We clearly see that the sdcard (mmcblk0) is 1 GB, the boot partition (mmcblk0p1) is 32 MB and the rootfs partition (mmcblk0p2) is 512 MB.</p>
  
  <p>So, to convince myself that the mmcblk0p2 partition may have been imporperly mounted, I mount it again with <code>mount -t ext4 -o rw /dev/mmcblk0p2 /mnt</code> and then I issue <code>df -h</code> again:</p>
  
  <pre><code>Filesystem                Size      Used Available Use% Mounted on
  /dev/root                17.1M     14.0M      1.8M  89% /
  devtmpfs                200.6M         0    200.6M   0% /dev
  tmpfs                   200.7M         0    200.7M   0% /dev/shm
  tmpfs                   200.7M         0    200.7M   0% /tmp
  tmpfs                   200.7M      4.0K    200.7M   0% /run
  /dev/mmcblk0p2           17.1M     14.0M      1.8M  89% /mnt
  </code></pre>
  
  <p>Again, I see that mmcblk0p2 size is 17.1 MB.</p>
  
  <p>So, my question is <strong>Why is <code>cat /proc/partitions</code> returning the expected size for my rootfs partition while <code>df -h</code> returns a totally different and bogus size ?</strong></p>