Implement new write protect for host commands.
Implement new write protect for host commands.

Rework to call functions in flash_common.c.

Also fixed a bug in parsing size of parse_offset_size().

Signed-off-by: Louis Yung-Chieh Lo <yjlou@chromium.org>

BUG=chrome-os-partner:8448
TEST=on link
(CONSOLE) flashwp set 0x3d000 0x1000
(CONSOLE) flashwp lock
(HOST)    flashrom -p internal:bus=lpc --wp-status
          WP: write protect is enabled
          WP: write protect range: start=0x0003d000, len=0x00001000

Change-Id: I4a53735c851ebf4bb0c01a55a1d301d5b706ee0c

akappy7/ChromeOS_EC_LED_Diagnostics,gelraen/cros-ec,coreboot/chrome-ec,coreboot/chrome-ec,alterapraxisptyltd/chromium-ec,thehobn/ec,alterapraxisptyltd/chromium-ec,md5555/ec,longsleep/ec,thehobn/ec,md5555/ec,eatbyte/chromium-ec,gelraen/cros-ec,alterapraxisptyltd/chromium-ec,thehobn/ec,longsleep/ec,coreboot/chrome-ec,gelraen/cros-ec,fourier49/BZ_DEV_EC,longsleep/ec,fourier49/BIZ_EC,thehobn/ec,akappy7/ChromeOS_EC_LED_Diagnostics,alterapraxisptyltd/chromium-ec,akappy7/ChromeOS_EC_LED_Diagnostics,mtk09422/chromiumos-platform-ec,fourier49/BZ_DEV_EC,coreboot/chrome-ec,md5555/ec,mtk09422/chromiumos-platform-ec,longsleep/ec,fourier49/BIZ_EC,mtk09422/chromiumos-platform-ec,eatbyte/chromium-ec,fourier49/BZ_DEV_EC,akappy7/ChromeOS_EC_LED_Diagnostics,mtk09422/chromiumos-platform-ec,akappy7/ChromeOS_EC_LED_Diagnostics,fourier49/BIZ_EC,fourier49/BZ_DEV_EC,coreboot/chrome-ec,md5555/ec,eatbyte/chromium-ec,coreboot/chrome-ec,eatbyte/chromium-ec,fourier49/BIZ_EC,gelraen/cros-ec