clk: h8300: fix error handling in h8s2678_pll_clk_setup()
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 14 May 2015 10:05:00 +0000 (13:05 +0300)
committerYoshinori Sato <ysato@users.sourceforge.jp>
Tue, 23 Jun 2015 04:35:58 +0000 (13:35 +0900)
commitded515a4d5561bc930de4e42a8621b1edd481f22
treefceaf8065900406433039ebf32f06190cc32bb39
parent389456b74007c6f455bec9d11e6c7cfc64d6e8d0
clk: h8300: fix error handling in h8s2678_pll_clk_setup()

The error handling was a bit messy and buggy.  It freed "pll_clock" then
dereferenced it, and then freed it again.  I've re-written it in normal
kernel style.

Fixes: 42ff8e8008c8 ('h8300: clock driver')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
drivers/clk/h8300/clk-h8s2678.c