ASoC: rt5645: Use devm_gpiod_get_optional for hp-detect
authorAxel Lin <axel.lin@ingics.com>
Fri, 12 Jun 2015 09:19:15 +0000 (17:19 +0800)
committerMark Brown <broonie@kernel.org>
Fri, 12 Jun 2015 10:52:29 +0000 (11:52 +0100)
commit25c8888ad65f812c847ae58398a5f8f1b20b0a95
tree3f32f4710b51dc43fae8747b8573f85f60123a1f
parent48edaa4b4fb6e75b890942394f0d0c2571d5c90d
ASoC: rt5645: Use devm_gpiod_get_optional for hp-detect

Since hp-detect is optional, use devm_gpiod_get_optional instead.
In additional, it should return error if devm_gpiod_get_optional fails.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt5645.c