Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 18d1dbf1 authored by Harvey Harrison's avatar Harvey Harrison Committed by Linus Torvalds
Browse files

ecryptfs: replace remaining __FUNCTION__ occurrences



__FUNCTION__ is gcc-specific, use __func__

Signed-off-by: default avatarHarvey Harrison <harvey.harrison@gmail.com>
Cc: Michael Halcrow <mhalcrow@us.ibm.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 05db67a4
Loading
Loading
Loading
Loading
+16 −16
Original line number Diff line number Diff line
@@ -119,21 +119,21 @@ static int ecryptfs_calculate_md5(char *dst,
	if (rc) {
		printk(KERN_ERR
		       "%s: Error initializing crypto hash; rc = [%d]\n",
		       __FUNCTION__, rc);
		       __func__, rc);
		goto out;
	}
	rc = crypto_hash_update(&desc, &sg, len);
	if (rc) {
		printk(KERN_ERR
		       "%s: Error updating crypto hash; rc = [%d]\n",
		       __FUNCTION__, rc);
		       __func__, rc);
		goto out;
	}
	rc = crypto_hash_final(&desc, dst);
	if (rc) {
		printk(KERN_ERR
		       "%s: Error finalizing crypto hash; rc = [%d]\n",
		       __FUNCTION__, rc);
		       __func__, rc);
		goto out;
	}
out:
@@ -437,7 +437,7 @@ static int ecryptfs_encrypt_extent(struct page *enc_extent_page,
	if (rc < 0) {
		printk(KERN_ERR "%s: Error attempting to encrypt page with "
		       "page->index = [%ld], extent_offset = [%ld]; "
		       "rc = [%d]\n", __FUNCTION__, page->index, extent_offset,
		       "rc = [%d]\n", __func__, page->index, extent_offset,
		       rc);
		goto out;
	}
@@ -487,7 +487,7 @@ int ecryptfs_encrypt_page(struct page *page)
						       0, PAGE_CACHE_SIZE);
		if (rc)
			printk(KERN_ERR "%s: Error attempting to copy "
			       "page at index [%ld]\n", __FUNCTION__,
			       "page at index [%ld]\n", __func__,
			       page->index);
		goto out;
	}
@@ -508,7 +508,7 @@ int ecryptfs_encrypt_page(struct page *page)
					     extent_offset);
		if (rc) {
			printk(KERN_ERR "%s: Error encrypting extent; "
			       "rc = [%d]\n", __FUNCTION__, rc);
			       "rc = [%d]\n", __func__, rc);
			goto out;
		}
		ecryptfs_lower_offset_for_extent(
@@ -569,7 +569,7 @@ static int ecryptfs_decrypt_extent(struct page *page,
	if (rc < 0) {
		printk(KERN_ERR "%s: Error attempting to decrypt to page with "
		       "page->index = [%ld], extent_offset = [%ld]; "
		       "rc = [%d]\n", __FUNCTION__, page->index, extent_offset,
		       "rc = [%d]\n", __func__, page->index, extent_offset,
		       rc);
		goto out;
	}
@@ -622,7 +622,7 @@ int ecryptfs_decrypt_page(struct page *page)
						      ecryptfs_inode);
		if (rc)
			printk(KERN_ERR "%s: Error attempting to copy "
			       "page at index [%ld]\n", __FUNCTION__,
			       "page at index [%ld]\n", __func__,
			       page->index);
		goto out;
	}
@@ -656,7 +656,7 @@ int ecryptfs_decrypt_page(struct page *page)
					     extent_offset);
		if (rc) {
			printk(KERN_ERR "%s: Error encrypting extent; "
			       "rc = [%d]\n", __FUNCTION__, rc);
			       "rc = [%d]\n", __func__, rc);
			goto out;
		}
	}
@@ -1215,7 +1215,7 @@ int ecryptfs_read_and_validate_header_region(char *data,
				 ecryptfs_inode);
	if (rc) {
		printk(KERN_ERR "%s: Error reading header region; rc = [%d]\n",
		       __FUNCTION__, rc);
		       __func__, rc);
		goto out;
	}
	if (!contains_ecryptfs_marker(data + ECRYPTFS_FILE_SIZE_BYTES)) {
@@ -1319,7 +1319,7 @@ ecryptfs_write_metadata_to_contents(struct ecryptfs_crypt_stat *crypt_stat,
				  0, crypt_stat->num_header_bytes_at_front);
	if (rc)
		printk(KERN_ERR "%s: Error attempting to write header "
		       "information to lower file; rc = [%d]\n", __FUNCTION__,
		       "information to lower file; rc = [%d]\n", __func__,
		       rc);
	return rc;
}
@@ -1364,14 +1364,14 @@ int ecryptfs_write_metadata(struct dentry *ecryptfs_dentry)
		}
	} else {
		printk(KERN_WARNING "%s: Encrypted flag not set\n",
		       __FUNCTION__);
		       __func__);
		rc = -EINVAL;
		goto out;
	}
	/* Released in this function */
	virt = kzalloc(crypt_stat->num_header_bytes_at_front, GFP_KERNEL);
	if (!virt) {
		printk(KERN_ERR "%s: Out of memory\n", __FUNCTION__);
		printk(KERN_ERR "%s: Out of memory\n", __func__);
		rc = -ENOMEM;
		goto out;
	}
@@ -1379,7 +1379,7 @@ int ecryptfs_write_metadata(struct dentry *ecryptfs_dentry)
					 ecryptfs_dentry);
	if (unlikely(rc)) {
		printk(KERN_ERR "%s: Error whilst writing headers; rc = [%d]\n",
		       __FUNCTION__, rc);
		       __func__, rc);
		goto out_free;
	}
	if (crypt_stat->flags & ECRYPTFS_METADATA_IN_XATTR)
@@ -1390,7 +1390,7 @@ int ecryptfs_write_metadata(struct dentry *ecryptfs_dentry)
							 ecryptfs_dentry, virt);
	if (rc) {
		printk(KERN_ERR "%s: Error writing metadata out to lower file; "
		       "rc = [%d]\n", __FUNCTION__, rc);
		       "rc = [%d]\n", __func__, rc);
		goto out_free;
	}
out_free:
@@ -1584,7 +1584,7 @@ int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry)
	if (!page_virt) {
		rc = -ENOMEM;
		printk(KERN_ERR "%s: Unable to allocate page_virt\n",
		       __FUNCTION__);
		       __func__);
		goto out;
	}
	rc = ecryptfs_read_lower(page_virt, 0, crypt_stat->extent_size,
+1 −1
Original line number Diff line number Diff line
@@ -500,7 +500,7 @@ ecryptfs_set_dentry_lower_mnt(struct dentry *dentry, struct vfsmount *lower_mnt)
}

#define ecryptfs_printk(type, fmt, arg...) \
        __ecryptfs_printk(type "%s: " fmt, __FUNCTION__, ## arg);
        __ecryptfs_printk(type "%s: " fmt, __func__, ## arg);
void __ecryptfs_printk(const char *fmt, ...);

extern const struct file_operations ecryptfs_main_fops;
+1 −1
Original line number Diff line number Diff line
@@ -121,7 +121,7 @@ ecryptfs_do_create(struct inode *directory_inode,
					     ecryptfs_dentry, mode, nd);
	if (rc) {
		printk(KERN_ERR "%s: Failure to create dentry in lower fs; "
		       "rc = [%d]\n", __FUNCTION__, rc);
		       "rc = [%d]\n", __func__, rc);
		goto out_lock;
	}
	rc = ecryptfs_interpose(lower_dentry, ecryptfs_dentry,
+1 −1
Original line number Diff line number Diff line
@@ -219,7 +219,7 @@ int ecryptfs_interpose(struct dentry *lower_dentry, struct dentry *dentry,
	if (rc) {
		printk(KERN_ERR "%s: Error attempting to initialize the "
		       "persistent file for the dentry with name [%s]; "
		       "rc = [%d]\n", __FUNCTION__, dentry->d_name.name, rc);
		       "rc = [%d]\n", __func__, dentry->d_name.name, rc);
		goto out;
	}
out:
+9 −9
Original line number Diff line number Diff line
@@ -153,7 +153,7 @@ ecryptfs_copy_up_encrypted_with_header(struct page *page,
			flush_dcache_page(page);
			if (rc) {
				printk(KERN_ERR "%s: Error reading xattr "
				       "region; rc = [%d]\n", __FUNCTION__, rc);
				       "region; rc = [%d]\n", __func__, rc);
				goto out;
			}
		} else {
@@ -169,7 +169,7 @@ ecryptfs_copy_up_encrypted_with_header(struct page *page,
			if (rc) {
				printk(KERN_ERR "%s: Error attempting to read "
				       "extent at offset [%lld] in the lower "
				       "file; rc = [%d]\n", __FUNCTION__,
				       "file; rc = [%d]\n", __func__,
				       lower_offset, rc);
				goto out;
			}
@@ -212,7 +212,7 @@ static int ecryptfs_readpage(struct file *file, struct page *page)
				       "the encrypted content from the lower "
				       "file whilst inserting the metadata "
				       "from the xattr into the header; rc = "
				       "[%d]\n", __FUNCTION__, rc);
				       "[%d]\n", __func__, rc);
				goto out;
			}

@@ -293,7 +293,7 @@ static int ecryptfs_prepare_write(struct file *file, struct page *page,
			if (rc) {
				printk(KERN_ERR "%s: Error attemping to read "
				       "lower page segment; rc = [%d]\n",
				       __FUNCTION__, rc);
				       __func__, rc);
				ClearPageUptodate(page);
				goto out;
			} else
@@ -308,7 +308,7 @@ static int ecryptfs_prepare_write(struct file *file, struct page *page,
					       "from the lower file whilst "
					       "inserting the metadata from "
					       "the xattr into the header; rc "
					       "= [%d]\n", __FUNCTION__, rc);
					       "= [%d]\n", __func__, rc);
					ClearPageUptodate(page);
					goto out;
				}
@@ -320,7 +320,7 @@ static int ecryptfs_prepare_write(struct file *file, struct page *page,
				if (rc) {
					printk(KERN_ERR "%s: Error reading "
					       "page; rc = [%d]\n",
					       __FUNCTION__, rc);
					       __func__, rc);
					ClearPageUptodate(page);
					goto out;
				}
@@ -331,7 +331,7 @@ static int ecryptfs_prepare_write(struct file *file, struct page *page,
			if (rc) {
				printk(KERN_ERR "%s: Error decrypting page "
				       "at index [%ld]; rc = [%d]\n",
				       __FUNCTION__, page->index, rc);
				       __func__, page->index, rc);
				ClearPageUptodate(page);
				goto out;
			}
@@ -348,7 +348,7 @@ static int ecryptfs_prepare_write(struct file *file, struct page *page,
			if (rc) {
				printk(KERN_ERR "%s: Error on attempt to "
				       "truncate to (higher) offset [%lld];"
				       " rc = [%d]\n", __FUNCTION__,
				       " rc = [%d]\n", __func__,
				       prev_page_end_size, rc);
				goto out;
			}
@@ -389,7 +389,7 @@ static int ecryptfs_write_inode_size_to_header(struct inode *ecryptfs_inode)
	kfree(file_size_virt);
	if (rc)
		printk(KERN_ERR "%s: Error writing file size to header; "
		       "rc = [%d]\n", __FUNCTION__, rc);
		       "rc = [%d]\n", __func__, rc);
out:
	return rc;
}
Loading