diff --git a/cipher/cipher-gcm.c b/cipher/cipher-gcm.c
index a9c48551..96219445 100644
--- a/cipher/cipher-gcm.c
+++ b/cipher/cipher-gcm.c
@@ -1178,39 +1178,6 @@ _gcry_cipher_gcm_setiv_zero (gcry_cipher_hd_t c)
 }
 
 
-#if 0 && TODO
-void
-_gcry_cipher_gcm_geniv (gcry_cipher_hd_t c,
-                        byte *ivout, size_t ivoutlen, const byte *nonce,
-                        size_t noncelen)
-{
-  /* nonce:    user provided part (might be null) */
-  /* noncelen: check if proper length (if nonce not null) */
-  /* ivout:    iv used to initialize gcm, output to user */
-  /* ivoutlen: check correct size */
-  byte iv[IVLEN];
-
-  if (!ivout)
-    return GPG_ERR_INV_ARG;
-  if (ivoutlen != IVLEN)
-    return GPG_ERR_INV_LENGTH;
-  if (nonce != NULL && !is_nonce_ok_len(noncelen))
-    return GPG_ERR_INV_ARG;
-
-  gcm_generate_iv(iv, nonce, noncelen);
-
-  c->marks.iv = 0;
-  c->marks.tag = 0;
-  c->u_mode.gcm.disallow_encryption_because_of_setiv_in_fips_mode = 0;
-
-  _gcry_cipher_gcm_initiv (c, iv, IVLEN);
-
-  buf_cpy(ivout, iv, IVLEN);
-  wipememory(iv, sizeof(iv));
-}
-#endif
-
-
 static int
 is_tag_length_valid(size_t taglen)
 {
