[PATCH] mm: fix multiple typos in multiple files

zhaimingbing posted 1 patch 2 years, 1 month ago
mm/io-mapping.c | 2 +-
mm/nommu.c      | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
[PATCH] mm: fix multiple typos in multiple files
Posted by zhaimingbing 2 years, 1 month ago
	nommu.c: Fix typo 'privatize'
	io-mapping.c: Fix typo 'pre-validation'

Signed-off-by: zhaimingbing <zhaimingbing@cmss.chinamobile.com>
---
 mm/io-mapping.c | 2 +-
 mm/nommu.c      | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/mm/io-mapping.c b/mm/io-mapping.c
index 01b362799..486598ba4 100644
--- a/mm/io-mapping.c
+++ b/mm/io-mapping.c
@@ -21,7 +21,7 @@ int io_mapping_map_user(struct io_mapping *iomap, struct vm_area_struct *vma,
 	if (WARN_ON_ONCE((vma->vm_flags & expected_flags) != expected_flags))
 		return -EINVAL;
 
-	/* We rely on prevalidation of the io-mapping to skip track_pfn(). */
+	/* We rely on pre-validation of the io-mapping to skip track_pfn(). */
 	return remap_pfn_range_notrack(vma, addr, pfn, size,
 		__pgprot((pgprot_val(iomap->prot) & _PAGE_CACHE_MASK) |
 			 (pgprot_val(vma->vm_page_prot) & ~_PAGE_CACHE_MASK)));
diff --git a/mm/nommu.c b/mm/nommu.c
index 7f9e9e5a0..40842b080 100644
--- a/mm/nommu.c
+++ b/mm/nommu.c
@@ -776,7 +776,7 @@ static int validate_mmap_request(struct file *file,
 			if (!(capabilities & NOMMU_MAP_DIRECT))
 				return -ENODEV;
 
-			/* we mustn't privatise shared mappings */
+			/* we mustn't privatize shared mappings */
 			capabilities &= ~NOMMU_MAP_COPY;
 		} else {
 			/* we're going to read the file into private memory we
-- 
2.33.0
Re: [PATCH] mm: fix multiple typos in multiple files
Posted by David Hildenbrand 2 years, 1 month ago
On 27.10.23 08:43, zhaimingbing wrote:
> 	nommu.c: Fix typo 'privatize'
> 	io-mapping.c: Fix typo 'pre-validation'

Unnecessary.

-- 
Cheers,

David / dhildenb
Re: [PATCH] mm: fix multiple typos in multiple files
Posted by Randy Dunlap 2 years, 1 month ago
Hi--

On 10/26/23 23:43, zhaimingbing wrote:
> 	nommu.c: Fix typo 'privatize'
> 	io-mapping.c: Fix typo 'pre-validation'
> 
> Signed-off-by: zhaimingbing <zhaimingbing@cmss.chinamobile.com>
> ---
>  mm/io-mapping.c | 2 +-
>  mm/nommu.c      | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/mm/io-mapping.c b/mm/io-mapping.c
> index 01b362799..486598ba4 100644
> --- a/mm/io-mapping.c
> +++ b/mm/io-mapping.c
> @@ -21,7 +21,7 @@ int io_mapping_map_user(struct io_mapping *iomap, struct vm_area_struct *vma,
>  	if (WARN_ON_ONCE((vma->vm_flags & expected_flags) != expected_flags))
>  		return -EINVAL;
>  
> -	/* We rely on prevalidation of the io-mapping to skip track_pfn(). */
> +	/* We rely on pre-validation of the io-mapping to skip track_pfn(). */

Not needed. The hyphen seems to be optional from what I see on the internet.

>  	return remap_pfn_range_notrack(vma, addr, pfn, size,
>  		__pgprot((pgprot_val(iomap->prot) & _PAGE_CACHE_MASK) |
>  			 (pgprot_val(vma->vm_page_prot) & ~_PAGE_CACHE_MASK)));
> diff --git a/mm/nommu.c b/mm/nommu.c
> index 7f9e9e5a0..40842b080 100644
> --- a/mm/nommu.c
> +++ b/mm/nommu.c
> @@ -776,7 +776,7 @@ static int validate_mmap_request(struct file *file,
>  			if (!(capabilities & NOMMU_MAP_DIRECT))
>  				return -ENODEV;
>  
> -			/* we mustn't privatise shared mappings */
> +			/* we mustn't privatize shared mappings */

We accept British spellings. :)

>  			capabilities &= ~NOMMU_MAP_COPY;
>  		} else {
>  			/* we're going to read the file into private memory we

Thanks.
-- 
~Randy