Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mfd: Use gpio_request_one from aat2870-core

Use gpio_request_one() instead of multiple gpiolib calls.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Jin Park <jinyoungp@nvidia.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>

authored by

Axel Lin and committed by
Samuel Ortiz
aced760d 61485c63

+2 -2
+2 -2
drivers/mfd/aat2870-core.c
··· 407 407 aat2870->init(aat2870); 408 408 409 409 if (aat2870->en_pin >= 0) { 410 - ret = gpio_request(aat2870->en_pin, "aat2870-en"); 410 + ret = gpio_request_one(aat2870->en_pin, GPIOF_OUT_INIT_HIGH, 411 + "aat2870-en"); 411 412 if (ret < 0) { 412 413 dev_err(&client->dev, 413 414 "Failed to request GPIO %d\n", aat2870->en_pin); 414 415 goto out_kfree; 415 416 } 416 - gpio_direction_output(aat2870->en_pin, 1); 417 417 } 418 418 419 419 aat2870_enable(aat2870);