tree: https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio.git gpio-descriptors-regulator head: 186f22f6b871b01dc5ed06f31c7a1e248133cd8c commit: 460e9d2590fedc3246482199186d7d0fd4a8f44a [15/26] regulator: lp8788-ldo: Pass descriptor instead of GPIO number config: x86_64-randconfig-x008-201800 (attached as .config) compiler: gcc-7 (Debian 7.2.0-12) 7.2.1 20171025 reproduce: git checkout 460e9d2590fedc3246482199186d7d0fd4a8f44a # save the attached .config to linux build tree make ARCH=x86_64 All errors (new ones prefixed by >>): drivers//regulator/lp8788-ldo.c: In function 'lp8788_config_ldo_enable_mode': >> drivers//regulator/lp8788-ldo.c:510:21: error: 'struct lp8788_ldo' has no member named 'ena' return PTR_ERR(ldo->ena->gpiod); ^~ vim +510 drivers//regulator/lp8788-ldo.c 464 465 static int lp8788_config_ldo_enable_mode(struct platform_device *pdev, 466 struct lp8788_ldo *ldo, 467 enum lp8788_ldo_id id) 468 { 469 struct lp8788 *lp = ldo->lp; 470 enum lp8788_ext_ldo_en_id enable_id; 471 u8 en_mask[] = { 472 [EN_ALDO1] = LP8788_EN_SEL_ALDO1_M, 473 [EN_ALDO234] = LP8788_EN_SEL_ALDO234_M, 474 [EN_ALDO5] = LP8788_EN_SEL_ALDO5_M, 475 [EN_ALDO7] = LP8788_EN_SEL_ALDO7_M, 476 [EN_DLDO7] = LP8788_EN_SEL_DLDO7_M, 477 [EN_DLDO911] = LP8788_EN_SEL_DLDO911_M, 478 }; 479 480 switch (id) { 481 case DLDO7: 482 enable_id = EN_DLDO7; 483 break; 484 case DLDO9: 485 case DLDO11: 486 enable_id = EN_DLDO911; 487 break; 488 case ALDO1: 489 enable_id = EN_ALDO1; 490 break; 491 case ALDO2 ... ALDO4: 492 enable_id = EN_ALDO234; 493 break; 494 case ALDO5: 495 enable_id = EN_ALDO5; 496 break; 497 case ALDO7: 498 enable_id = EN_ALDO7; 499 break; 500 default: 501 return 0; 502 } 503 504 /* FIXME: check default mode for GPIO here: high or low? */ 505 ldo->ena_gpiod = devm_gpiod_get_index_optional(&pdev->dev, 506 "enable", 507 enable_id, 508 GPIOD_OUT_HIGH); 509 if (IS_ERR(ldo->ena_gpiod)) > 510 return PTR_ERR(ldo->ena->gpiod); 511 512 /* if no GPIO for ldo pin, then set default enable mode */ 513 if (!ldo->ena_gpiod) 514 goto set_default_ldo_enable_mode; 515 516 return 0; 517 518 set_default_ldo_enable_mode: 519 return lp8788_update_bits(lp, LP8788_EN_SEL, en_mask[enable_id], 0); 520 } 521 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
Attachment:
.config.gz
Description: application/gzip