Repository navigation
Commit ce83d21
thp: allocate memory in khugepaged outside of mmap_sem write mode
This tries to be more friendly to filesystem in userland, with userland
backends that allocate memory in the I/O paths and that could deadlock if
khugepaged holds the mmap_sem write mode of the userland backend while
allocating memory. Memory allocation may wait for writeback I/O
completion from the daemon that may be blocked in the mmap_sem read mode
if a page fault happens and the daemon wasn't using mlock for the memory
required for the I/O submission and completion.
Signed-off-by: Andrea Arcangeli <aarcange@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>1 parent 0bbbc0b commit ce83d21
1 file changed
Lines changed: 34 additions & 22 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1664 | 1664 | | |
1665 | 1665 | | |
1666 | 1666 | | |
1667 | | - | |
| 1667 | + | |
| 1668 | + | |
1668 | 1669 | | |
1669 | | - | |
1670 | 1670 | | |
1671 | 1671 | | |
1672 | 1672 | | |
| |||
1680 | 1680 | | |
1681 | 1681 | | |
1682 | 1682 | | |
| 1683 | + | |
1683 | 1684 | | |
1684 | 1685 | | |
| 1686 | + | |
| 1687 | + | |
| 1688 | + | |
| 1689 | + | |
| 1690 | + | |
| 1691 | + | |
| 1692 | + | |
| 1693 | + | |
| 1694 | + | |
| 1695 | + | |
| 1696 | + | |
| 1697 | + | |
| 1698 | + | |
| 1699 | + | |
| 1700 | + | |
| 1701 | + | |
1685 | 1702 | | |
| 1703 | + | |
| 1704 | + | |
| 1705 | + | |
| 1706 | + | |
| 1707 | + | |
| 1708 | + | |
| 1709 | + | |
| 1710 | + | |
1686 | 1711 | | |
1687 | 1712 | | |
1688 | 1713 | | |
| |||
1720 | 1745 | | |
1721 | 1746 | | |
1722 | 1747 | | |
1723 | | - | |
1724 | | - | |
1725 | | - | |
1726 | | - | |
1727 | | - | |
1728 | | - | |
1729 | | - | |
1730 | | - | |
1731 | | - | |
1732 | | - | |
1733 | | - | |
1734 | | - | |
1735 | 1748 | | |
1736 | 1749 | | |
1737 | 1750 | | |
| |||
1759 | 1772 | | |
1760 | 1773 | | |
1761 | 1774 | | |
1762 | | - | |
| 1775 | + | |
1763 | 1776 | | |
1764 | 1777 | | |
1765 | 1778 | | |
| |||
1798 | 1811 | | |
1799 | 1812 | | |
1800 | 1813 | | |
1801 | | - | |
| 1814 | + | |
1802 | 1815 | | |
1803 | 1816 | | |
1804 | 1817 | | |
1805 | | - | |
| 1818 | + | |
1806 | 1819 | | |
1807 | 1820 | | |
1808 | 1821 | | |
1809 | | - | |
| 1822 | + | |
1810 | 1823 | | |
1811 | 1824 | | |
1812 | 1825 | | |
| |||
1865 | 1878 | | |
1866 | 1879 | | |
1867 | 1880 | | |
1868 | | - | |
1869 | | - | |
1870 | | - | |
1871 | | - | |
| 1881 | + | |
| 1882 | + | |
| 1883 | + | |
1872 | 1884 | | |
1873 | 1885 | | |
1874 | 1886 | | |
| |||
0 commit comments