Commit c633e48
spi: atmel: use managed resource for gpio chip select
Use the managed gpio CS pin request so that we avoid having trouble
in the cleanup code.
In fact, if module was configured with DT, cleanup code released
invalid pin. Since resource wasn't freed, module cannot be reinserted.
This require to extract the gpio request call from the "setup" function
and call it in the appropriate probe function.
Reported-by: Alexander Morozov <linux@meltdown.ru>
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>1 parent 69973b8 commit c633e48
1 file changed
Lines changed: 39 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| 27 | + | |
27 | 28 | | |
28 | 29 | | |
29 | 30 | | |
| |||
1204 | 1205 | | |
1205 | 1206 | | |
1206 | 1207 | | |
1207 | | - | |
1208 | 1208 | | |
1209 | 1209 | | |
1210 | 1210 | | |
| |||
1247 | 1247 | | |
1248 | 1248 | | |
1249 | 1249 | | |
1250 | | - | |
1251 | | - | |
1252 | | - | |
1253 | | - | |
1254 | | - | |
1255 | | - | |
1256 | | - | |
| 1250 | + | |
1257 | 1251 | | |
1258 | 1252 | | |
1259 | | - | |
1260 | 1253 | | |
1261 | 1254 | | |
1262 | 1255 | | |
| |||
1471 | 1464 | | |
1472 | 1465 | | |
1473 | 1466 | | |
1474 | | - | |
1475 | 1467 | | |
1476 | 1468 | | |
1477 | 1469 | | |
1478 | 1470 | | |
1479 | 1471 | | |
1480 | | - | |
1481 | 1472 | | |
1482 | 1473 | | |
1483 | 1474 | | |
| |||
1499 | 1490 | | |
1500 | 1491 | | |
1501 | 1492 | | |
| 1493 | + | |
| 1494 | + | |
| 1495 | + | |
| 1496 | + | |
| 1497 | + | |
| 1498 | + | |
| 1499 | + | |
| 1500 | + | |
| 1501 | + | |
| 1502 | + | |
| 1503 | + | |
| 1504 | + | |
| 1505 | + | |
| 1506 | + | |
| 1507 | + | |
| 1508 | + | |
| 1509 | + | |
| 1510 | + | |
| 1511 | + | |
| 1512 | + | |
| 1513 | + | |
| 1514 | + | |
| 1515 | + | |
| 1516 | + | |
| 1517 | + | |
| 1518 | + | |
| 1519 | + | |
| 1520 | + | |
| 1521 | + | |
| 1522 | + | |
| 1523 | + | |
| 1524 | + | |
| 1525 | + | |
1502 | 1526 | | |
1503 | 1527 | | |
1504 | 1528 | | |
| |||
1577 | 1601 | | |
1578 | 1602 | | |
1579 | 1603 | | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
1580 | 1608 | | |
1581 | 1609 | | |
1582 | 1610 | | |
| |||
0 commit comments