Giter VIP home page Giter VIP logo

Comments (11)

JaybeamChing avatar JaybeamChing commented on July 18, 2024 1

Yes, you have gotten the point, the key point is "different destination buffer", and no crash happened with in-place operations.
So sorry to have bother you, wish you have a happy vacation.
Thanks!

from cryptodev-linux.

cristian-stoica avatar cristian-stoica commented on July 18, 2024

What AES (from the panic) test did you run and what kernel algortithm(s) did you enabled? What are the versions of kernel and cryptodev?

from cryptodev-linux.

JaybeamChing avatar JaybeamChing commented on July 18, 2024

aes_test was a testing program of user space, and it was coded after the file examples/aes.c. I put the three functions: aes_ctx_init, aes_encrypt,aes_ctx_deinit into a while loop for a longtime test, and killed the aes_test while it was running. Kernel algortithm was xts(aes), and I just added several lines to crypto_create_session to support this algortithm. The version of cryptodev is 1.9, and kernel is 4.1.46. The
kernel algortithm(s) I enabled were: stdrng, lzo, crct10dif, crc32c, ecb(arc4), arc4, aes, des3_ede, des, sha224, sha256, sha1, md5, md4.

from cryptodev-linux.

cristian-stoica avatar cristian-stoica commented on July 18, 2024

Did you get the crash also with vanilla examples/aes.c or with some of the tests? You could modify them to run a little longer for an easy time to CTRL-C.
The kernel algorithms question was to see if you run a software or a hardware AES driver - it is irrelevant though since the crash is on a different code path.

You can try this branch, we did not see issues with it at the time. If you do, let me know your results

https://github.com/cristian-stoica/cryptodev-linux/tree/umaster

from cryptodev-linux.

JaybeamChing avatar JaybeamChing commented on July 18, 2024

I just used the branch you gave to test again, and modified examples/aes.c, made the source address and destination address different in the aes_encrypt function. I tested kill -9 or -15 while running for several times, the crash always happened. Now I'm not sure the problem belongs to cryptodev or the kernel, I will change the kernel version to test it again, and maybe tomorrow I could give you the result. Thank you very much!

from cryptodev-linux.

cristian-stoica avatar cristian-stoica commented on July 18, 2024

If I understand you correctly you always get the crash with different destination buffer but not with in-place operations? This sounds like something worth investigating.
I'm going in vacation so we may continue the discussion in a couple of weeks. Otherwise feel free to submit a pull request if you stumble upon a patch.

from cryptodev-linux.

JaybeamChing avatar JaybeamChing commented on July 18, 2024

This week , I did the same test with other kernel version——4.10.0-42-generic,and it also reported calltrace information as following:
[10420.249240] [] release_user_pages+0x90/0x100 [cryptodev]
[10420.249246] [] get_userbuf+0x228/0x310 [cryptodev]
[10420.249252] [] crypto_run+0x1c8/0x4a8 [cryptodev]
[10420.249257] [] cryptodev_ioctl+0x520/0x7d8 [cryptodev]
[10420.249260] [] do_vfs_ioctl+0xc4/0x8e8
[10420.249262] [] SyS_ioctl+0x94/0xa8
[10420.249264] [] el0_svc_naked+0x24/0x28
[10420.249266] Code: 52800080 d37df035 f8617841 8b150042 (f9400023)
[10420.249268] ---[ end trace a5d9b3b46941a846 ]---

So I think this problem has nothing with kernel version. I will be glad to research it with you when you return to work.

from cryptodev-linux.

cristian-stoica avatar cristian-stoica commented on July 18, 2024

@JaybeamChing Am I wrong to ask if you've got a patch for this?

from cryptodev-linux.

JaybeamChing avatar JaybeamChing commented on July 18, 2024

Not yet, I am still not sure how to solve this problem.

from cryptodev-linux.

JaybeamChing avatar JaybeamChing commented on July 18, 2024

Do you have any idea how to fix this bug now?

from cryptodev-linux.

cristian-stoica avatar cristian-stoica commented on July 18, 2024

@JaybeamChing I'm sorry I don't have a solution for you. I am currently involved in other projects and not actively debugging this issue.

from cryptodev-linux.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.